mirror of
https://github.com/italicsjenga/winit-sonoma-fix.git
synced 2024-12-25 06:41:31 +11:00
Merge pull request #298 from andreasgal/master
Make headless rendering work on Mac OS X 10.10
This commit is contained in:
commit
65046ffc41
|
@ -1,7 +1,7 @@
|
||||||
[package]
|
[package]
|
||||||
|
|
||||||
name = "glutin"
|
name = "glutin"
|
||||||
version = "0.0.5"
|
version = "0.0.6"
|
||||||
authors = ["tomaka <pierre.krieger1708@gmail.com>"]
|
authors = ["tomaka <pierre.krieger1708@gmail.com>"]
|
||||||
description = "Cross-plaform OpenGL context provider. Important: the crates.io only supports Windows and Linux for the moment."
|
description = "Cross-plaform OpenGL context provider. Important: the crates.io only supports Windows and Linux for the moment."
|
||||||
keywords = ["windowing", "opengl"]
|
keywords = ["windowing", "opengl"]
|
||||||
|
|
|
@ -28,13 +28,9 @@ impl HeadlessContext {
|
||||||
let (width, height) = builder.dimensions.unwrap_or((1024, 768));
|
let (width, height) = builder.dimensions.unwrap_or((1024, 768));
|
||||||
let context = unsafe {
|
let context = unsafe {
|
||||||
let attributes = [
|
let attributes = [
|
||||||
|
NSOpenGLPFAAccelerated as u32,
|
||||||
|
NSOpenGLPFAAllowOfflineRenderers as u32,
|
||||||
NSOpenGLPFADoubleBuffer as u32,
|
NSOpenGLPFADoubleBuffer as u32,
|
||||||
NSOpenGLPFAClosestPolicy as u32,
|
|
||||||
NSOpenGLPFAColorSize as u32, 24,
|
|
||||||
NSOpenGLPFAAlphaSize as u32, 8,
|
|
||||||
NSOpenGLPFADepthSize as u32, 24,
|
|
||||||
NSOpenGLPFAStencilSize as u32, 8,
|
|
||||||
NSOpenGLPFAOffScreen as u32,
|
|
||||||
0
|
0
|
||||||
];
|
];
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue