[−][src]Struct offscreen_gl_context::GLContext
This is a wrapper over a native headless GL context
Methods
impl<Native> GLContext<Native> where
Native: NativeGLContextMethods,
[src]
Native: NativeGLContextMethods,
pub fn create(
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>
) -> Result<Self, &'static str>
[src]
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>
) -> Result<Self, &'static str>
pub fn create_shared_with_dispatcher(
api_type: &GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>,
dispatcher: Option<Box<dyn GLContextDispatcher>>
) -> Result<Self, &'static str>
[src]
api_type: &GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>,
dispatcher: Option<Box<dyn GLContextDispatcher>>
) -> Result<Self, &'static str>
pub fn get_proc_address(addr: &str) -> *const ()
[src]
pub fn current_handle() -> Option<Native::Handle>
[src]
pub fn new(
size: Size2D<i32>,
attributes: GLContextAttributes,
color_attachment_type: ColorAttachmentType,
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>
) -> Result<Self, &'static str>
[src]
size: Size2D<i32>,
attributes: GLContextAttributes,
color_attachment_type: ColorAttachmentType,
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>
) -> Result<Self, &'static str>
pub fn new_shared_with_dispatcher(
size: Size2D<i32>,
attributes: GLContextAttributes,
color_attachment_type: ColorAttachmentType,
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>,
dispatcher: Option<Box<dyn GLContextDispatcher>>
) -> Result<Self, &'static str>
[src]
size: Size2D<i32>,
attributes: GLContextAttributes,
color_attachment_type: ColorAttachmentType,
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>,
dispatcher: Option<Box<dyn GLContextDispatcher>>
) -> Result<Self, &'static str>
pub fn with_default_color_attachment(
size: Size2D<i32>,
attributes: GLContextAttributes,
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>
) -> Result<Self, &'static str>
[src]
size: Size2D<i32>,
attributes: GLContextAttributes,
api_type: GlType,
api_version: GLVersion,
shared_with: Option<&Native::Handle>
) -> Result<Self, &'static str>
pub fn make_current(&self) -> Result<(), &'static str>
[src]
pub fn unbind(&self) -> Result<(), &'static str>
[src]
pub fn is_current(&self) -> bool
[src]
pub fn handle(&self) -> Native::Handle
[src]
pub fn gl(&self) -> &Gl
[src]
pub fn clone_gl(&self) -> Rc<Gl>
[src]
pub fn borrow_attributes(&self) -> &GLContextAttributes
[src]
pub fn borrow_capabilities(&self) -> &GLContextCapabilities
[src]
pub fn borrow_formats(&self) -> &GLFormats
[src]
pub fn borrow_limits(&self) -> &GLLimits
[src]
pub fn borrow_draw_buffer(&self) -> Option<&DrawBuffer>
[src]
pub fn get_framebuffer(&self) -> GLuint
[src]
pub fn draw_buffer_size(&self) -> Option<Size2D<i32>>
[src]
pub fn resize(&mut self, size: Size2D<i32>) -> Result<DrawBuffer, &'static str>
[src]
pub fn get_extensions(&self) -> Vec<String>
[src]
Auto Trait Implementations
impl<Native> Unpin for GLContext<Native> where
Native: Unpin,
Native: Unpin,
impl<Native> !Sync for GLContext<Native>
impl<Native> !Send for GLContext<Native>
impl<Native> UnwindSafe for GLContext<Native> where
Native: UnwindSafe,
Native: UnwindSafe,
impl<Native> !RefUnwindSafe for GLContext<Native>
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,