[−][src]Function gles30::load_gles_with
pub unsafe fn load_gles_with<F>(load_fn: F) where
F: FnMut(*const c_char) -> *const c_void,
Load each GLES symbol using a provided loader function.
This allows for the use of functions like glfwGetProcAddress
or
SDL_GL_GetProcAddress
.
ⓘThis example is not tested
gles30::load_with(|ptr| SDL_GL_GetProcAddress(ptr));
Function loading will attempt to use fallback options if the first lookup fails.
Safety
- This mostly trusts whatever the loader function says, so the loader must provide the correct pointer or a null pointer for each request.