pub struct Context {
raw: GlFns,
extensions: HashSet<String, RandomState>,
constants: Constants,
version: Version,
}
Expand description
Re-exported glow::Context
.
Fields§
§raw: GlFns
§extensions: HashSet<String, RandomState>
§constants: Constants
§version: Version
Implementations§
source§impl Context
impl Context
pub unsafe fn from_loader_function_cstr<F>(loader_function: F) -> Contextwhere F: FnMut(&CStr) -> *const c_void,
pub unsafe fn from_loader_function<F>(loader_function: F) -> Contextwhere F: FnMut(&str) -> *const c_void,
sourcepub unsafe fn create_texture_from_gl_name(gl_name: u32) -> NativeTexture
👎Deprecated: Use the NativeTexture constructor instead
pub unsafe fn create_texture_from_gl_name(gl_name: u32) -> NativeTexture
Creates a texture from an external GL name.
This can be useful when a texture is created outside of glow (e.g. OpenXR surface) but glow still needs access to it for rendering.
sourcepub unsafe fn create_framebuffer_from_gl_name(gl_name: u32) -> NativeFramebuffer
👎Deprecated: Use the NativeFramebuffer constructor instead
pub unsafe fn create_framebuffer_from_gl_name(gl_name: u32) -> NativeFramebuffer
Creates a framebuffer from an external GL name.
This can be useful when a framebuffer is created outside of glow (e.g: via surfman
or another
crate that supports sharing of buffers between GL contexts), but glow needs to set it as a target.