Skip to content

Commit 1bd2164

Browse files
authored
Fix examples on macos. (rust-windowing#1201)
Signed-off-by: Hal Gentz <zegentzy@protonmail.com>
1 parent 415f0b6 commit 1bd2164

File tree

1 file changed

+0
-25
lines changed
  • glutin_examples/examples/support

1 file changed

+0
-25
lines changed

glutin_examples/examples/support/mod.rs

-25
Original file line numberDiff line numberDiff line change
@@ -11,35 +11,10 @@ pub struct Gl {
1111
pub gl: gl::Gl,
1212
}
1313

14-
extern "system" fn dbg_callback(
15-
source: gl::types::GLenum,
16-
etype: gl::types::GLenum,
17-
_id: gl::types::GLuint,
18-
severity: gl::types::GLenum,
19-
_msg_length: gl::types::GLsizei,
20-
msg: *const gl::types::GLchar,
21-
_user_data: *mut std::ffi::c_void,
22-
) {
23-
unsafe {
24-
println!(
25-
"dbg_callback {:#X} {:#X} {:#X} {:?}",
26-
source,
27-
etype,
28-
severity,
29-
std::ffi::CStr::from_ptr(msg),
30-
);
31-
}
32-
}
33-
3414
pub fn load(gl_context: &glutin::Context<PossiblyCurrent>) -> Gl {
3515
let gl =
3616
gl::Gl::load_with(|ptr| gl_context.get_proc_address(ptr) as *const _);
3717

38-
unsafe {
39-
gl.Enable(gl::DEBUG_OUTPUT);
40-
gl.DebugMessageCallback(dbg_callback, std::ptr::null());
41-
}
42-
4318
let version = unsafe {
4419
let data = CStr::from_ptr(gl.GetString(gl::VERSION) as *const _)
4520
.to_bytes()

0 commit comments

Comments
 (0)