glutin_glx_sys/
lib.rs

1#![cfg(any(
2    target_os = "linux",
3    target_os = "dragonfly",
4    target_os = "freebsd",
5    target_os = "netbsd",
6    target_os = "openbsd"
7))]
8#![allow(clippy::missing_safety_doc)]
9#![allow(clippy::manual_non_exhaustive)]
10#![allow(clippy::unused_unit)]
11#![allow(clippy::redundant_static_lifetimes)]
12#![allow(clippy::unnecessary_cast)]
13#![allow(unknown_lints, clippy::missing_transmute_annotations)]
14
15pub use self::glx::types::GLXContext;
16pub use x11_dl::xlib::*;
17
18/// GLX bindings
19pub mod glx {
20    include!(concat!(env!("OUT_DIR"), "/glx_bindings.rs"));
21
22    // The GLX protocol error codes extracted from <GL/glxproto.h>.
23    pub const PROTO_BAD_CONTEXT: types::GLenum = 0;
24    pub const PROTO_BAD_CONTEXT_STATE: types::GLenum = 1;
25    pub const PROTO_BAD_DRAWABLE: types::GLenum = 2;
26    pub const PROTO_BAD_PIXMAP: types::GLenum = 3;
27    pub const PROTO_BAD_CONTEXT_TAG: types::GLenum = 4;
28    pub const PROTO_BAD_CURRENT_WINDOW: types::GLenum = 5;
29    pub const PROTO_BAD_RENDER_REQUEST: types::GLenum = 6;
30    pub const PROTO_BAD_LARGE_REQUEST: types::GLenum = 7;
31    pub const PROTO_UNSUPPORTED_PRIVATE_REQUEST: types::GLenum = 8;
32    pub const PROTO_BAD_FBCONFIG: types::GLenum = 9;
33    pub const PROTO_BAD_PBUFFER: types::GLenum = 10;
34    pub const PROTO_BAD_CURRENT_DRAWABLE: types::GLenum = 11;
35    pub const PROTO_BAD_WINDOW: types::GLenum = 12;
36    pub const PROTO_BAD_PROFILE_ARB: types::GLenum = 13;
37}
38
39/// Functions that are not necessarily always available
40pub mod glx_extra {
41    include!(concat!(env!("OUT_DIR"), "/glx_extra_bindings.rs"));
42}