Struct glfw::RenderContext
source · pub struct RenderContext { /* private fields */ }
Expand description
A rendering context that can be shared between tasks.
Implementations§
source§impl RenderContext
impl RenderContext
sourcepub fn get_proc_address(&mut self, procname: &str) -> GLProc
pub fn get_proc_address(&mut self, procname: &str) -> GLProc
Wrapper function, please refer to Window::get_proc_address
Trait Implementations§
source§impl Context for RenderContext
impl Context for RenderContext
source§fn window_ptr(&self) -> *mut GLFWwindow
fn window_ptr(&self) -> *mut GLFWwindow
Returns the pointer to the underlying
GLFWwindow
.source§fn swap_buffers(&mut self)
fn swap_buffers(&mut self)
Swaps the front and back buffers of the window. If the swap interval is
greater than zero, the GPU driver waits the specified number of screen
updates before swapping the buffers. Read more
source§fn is_current(&self) -> bool
fn is_current(&self) -> bool
Returns
true
if the window is the current context.source§fn make_current(&mut self)
fn make_current(&mut self)
Wrapper for
glfwMakeContextCurrent
source§fn should_close(&self) -> bool
fn should_close(&self) -> bool
Wrapper for
glfwWindowShouldClose
.source§fn set_should_close(&mut self, value: bool)
fn set_should_close(&mut self, value: bool)
Wrapper for
glfwSetWindowShouldClose
.source§fn post_empty_event(&self)
fn post_empty_event(&self)
Wrapper for
glfwPostEmptyEvent
.source§impl Debug for RenderContext
impl Debug for RenderContext
source§impl HasDisplayHandle for RenderContext
impl HasDisplayHandle for RenderContext
source§fn display_handle(&self) -> Result<DisplayHandle<'_>, HandleError>
fn display_handle(&self) -> Result<DisplayHandle<'_>, HandleError>
Get a handle to the display controller of the windowing system.
source§impl HasWindowHandle for RenderContext
impl HasWindowHandle for RenderContext
source§fn window_handle(&self) -> Result<WindowHandle<'_>, HandleError>
fn window_handle(&self) -> Result<WindowHandle<'_>, HandleError>
Get a handle to the window.
impl Send for RenderContext
Auto Trait Implementations§
impl RefUnwindSafe for RenderContext
impl !Sync for RenderContext
impl Unpin for RenderContext
impl UnwindSafe for RenderContext
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> HasRawDisplayHandle for Twhere
T: HasDisplayHandle + ?Sized,
impl<T> HasRawDisplayHandle for Twhere
T: HasDisplayHandle + ?Sized,
source§fn raw_display_handle(&self) -> Result<RawDisplayHandle, HandleError>
fn raw_display_handle(&self) -> Result<RawDisplayHandle, HandleError>
👎Deprecated: Use
HasDisplayHandle
insteadsource§impl<T> HasRawWindowHandle for Twhere
T: HasWindowHandle + ?Sized,
impl<T> HasRawWindowHandle for Twhere
T: HasWindowHandle + ?Sized,
source§fn raw_window_handle(&self) -> Result<RawWindowHandle, HandleError>
fn raw_window_handle(&self) -> Result<RawWindowHandle, HandleError>
👎Deprecated: Use
HasWindowHandle
instead