Extract WindowAttributes from the BuilderAttribs
This commit is contained in:
parent
c244f8c033
commit
48fe9b2644
12 changed files with 106 additions and 67 deletions
|
|
@ -28,7 +28,7 @@ pub struct HeadlessContext {
|
|||
|
||||
impl HeadlessContext {
|
||||
pub fn new(builder: BuilderAttribs) -> Result<HeadlessContext, CreationError> {
|
||||
let (width, height) = builder.dimensions.unwrap_or((1024, 768));
|
||||
let (width, height) = builder.window.dimensions.unwrap_or((1024, 768));
|
||||
let context = unsafe {
|
||||
let attributes = [
|
||||
NSOpenGLPFAAccelerated as u32,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue