glium_pib

Struct Window

Source
pub struct Window<S>
where S: Deref<Target = System>,
{ pub system: S, /* private fields */ }
Expand description

A (fullscreen) window.

Fields§

§system: S

The system.

Implementations§

Source§

impl<S> Window<S>
where S: Deref<Target = System>,

Source

pub fn new(system: S, config: &WindowConfig) -> Result<Self, Error>

Create a window.

Trait Implementations§

Source§

impl<S> Backend for Window<S>
where S: Deref<Target = System>,

Source§

unsafe fn make_current(&self)

Makes the OpenGL context the current context in the current thread.

Source§

fn swap_buffers(&self) -> Result<(), SwapBuffersError>

Swaps buffers at the end of a frame.
Source§

unsafe fn get_proc_address(&self, symbol: &str) -> *const c_void

Returns the address of an OpenGL function. Read more
Source§

fn get_framebuffer_dimensions(&self) -> (u32, u32)

Returns the dimensions of the window, or screen, etc.
Source§

fn is_current(&self) -> bool

Returns true if the OpenGL context is the current one in the thread.
Source§

impl<S> Drop for Window<S>
where S: Deref<Target = System>,

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more

Auto Trait Implementations§

§

impl<S> Freeze for Window<S>
where S: Freeze,

§

impl<S> RefUnwindSafe for Window<S>
where S: RefUnwindSafe,

§

impl<S> !Send for Window<S>

§

impl<S> !Sync for Window<S>

§

impl<S> Unpin for Window<S>
where S: Unpin,

§

impl<S> UnwindSafe for Window<S>
where S: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.