pub struct Wgl {
Show 28 fields pub ChoosePixelFormatARB: FnPtr, pub CopyContext: FnPtr, pub CreateContext: FnPtr, pub CreateContextAttribsARB: FnPtr, pub CreateLayerContext: FnPtr, pub DeleteContext: FnPtr, pub DescribeLayerPlane: FnPtr, pub GetCurrentContext: FnPtr, pub GetCurrentDC: FnPtr, pub GetExtensionsStringARB: FnPtr, pub GetExtensionsStringEXT: FnPtr, pub GetLayerPaletteEntries: FnPtr, pub GetPixelFormatAttribfvARB: FnPtr, pub GetPixelFormatAttribivARB: FnPtr, pub GetProcAddress: FnPtr, pub GetSwapIntervalEXT: FnPtr, pub MakeCurrent: FnPtr, pub RealizeLayerPalette: FnPtr, pub SetLayerPaletteEntries: FnPtr, pub ShareLists: FnPtr, pub SwapIntervalEXT: FnPtr, pub SwapLayerBuffers: FnPtr, pub UseFontBitmaps: FnPtr, pub UseFontBitmapsA: FnPtr, pub UseFontBitmapsW: FnPtr, pub UseFontOutlines: FnPtr, pub UseFontOutlinesA: FnPtr, pub UseFontOutlinesW: FnPtr, /* private fields */
}

Fields§

§ChoosePixelFormatARB: FnPtr§CopyContext: FnPtr§CreateContext: FnPtr§CreateContextAttribsARB: FnPtr§CreateLayerContext: FnPtr§DeleteContext: FnPtr§DescribeLayerPlane: FnPtr§GetCurrentContext: FnPtr§GetCurrentDC: FnPtr§GetExtensionsStringARB: FnPtr§GetExtensionsStringEXT: FnPtr§GetLayerPaletteEntries: FnPtr§GetPixelFormatAttribfvARB: FnPtr§GetPixelFormatAttribivARB: FnPtr§GetProcAddress: FnPtr§GetSwapIntervalEXT: FnPtr§MakeCurrent: FnPtr§RealizeLayerPalette: FnPtr§SetLayerPaletteEntries: FnPtr§ShareLists: FnPtr§SwapIntervalEXT: FnPtr§SwapLayerBuffers: FnPtr§UseFontBitmaps: FnPtr§UseFontBitmapsA: FnPtr§UseFontBitmapsW: FnPtr§UseFontOutlines: FnPtr§UseFontOutlinesA: FnPtr§UseFontOutlinesW: FnPtr

Implementations§

source§

impl Wgl

source

pub fn load_with<F>(loadfn: F) -> Wglwhere F: FnMut(&'static str) -> *const c_void,

Load each OpenGL symbol using a custom load function. This allows for the use of functions like glfwGetProcAddress or SDL_GL_GetProcAddress.

let gl = Gl::load_with(|s| glfw.get_proc_address(s));
source

pub unsafe fn ChoosePixelFormatARB( &self, hdc: *const c_void, piAttribIList: *const i32, pfAttribFList: *const f32, nMaxFormats: u32, piFormats: *mut i32, nNumFormats: *mut u32 ) -> i32

source

pub unsafe fn CopyContext( &self, hglrcSrc: *const c_void, hglrcDst: *const c_void, mask: u32 ) -> i32

source

pub unsafe fn CreateContext(&self, hDc: *const c_void) -> *const c_void

source

pub unsafe fn CreateContextAttribsARB( &self, hDC: *const c_void, hShareContext: *const c_void, attribList: *const i32 ) -> *const c_void

source

pub unsafe fn CreateLayerContext( &self, hDc: *const c_void, level: i32 ) -> *const c_void

source

pub unsafe fn DeleteContext(&self, oldContext: *const c_void) -> i32

source

pub unsafe fn DescribeLayerPlane( &self, hDc: *const c_void, pixelFormat: i32, layerPlane: i32, nBytes: u32, plpd: *const LAYERPLANEDESCRIPTOR ) -> i32

source

pub unsafe fn GetCurrentContext(&self) -> *const c_void

source

pub unsafe fn GetCurrentDC(&self) -> *const c_void

source

pub unsafe fn GetExtensionsStringARB(&self, hdc: *const c_void) -> *const i8

source

pub unsafe fn GetExtensionsStringEXT(&self) -> *const i8

source

pub unsafe fn GetLayerPaletteEntries( &self, hdc: *const c_void, iLayerPlane: i32, iStart: i32, cEntries: i32, pcr: *const u32 ) -> i32

source

pub unsafe fn GetPixelFormatAttribfvARB( &self, hdc: *const c_void, iPixelFormat: i32, iLayerPlane: i32, nAttributes: u32, piAttributes: *const i32, pfValues: *mut f32 ) -> i32

source

pub unsafe fn GetPixelFormatAttribivARB( &self, hdc: *const c_void, iPixelFormat: i32, iLayerPlane: i32, nAttributes: u32, piAttributes: *const i32, piValues: *mut i32 ) -> i32

source

pub unsafe fn GetProcAddress(&self, lpszProc: *const i8) -> *mut __PROC_fn

source

pub unsafe fn GetSwapIntervalEXT(&self) -> i32

source

pub unsafe fn MakeCurrent( &self, hDc: *const c_void, newContext: *const c_void ) -> i32

source

pub unsafe fn RealizeLayerPalette( &self, hdc: *const c_void, iLayerPlane: i32, bRealize: i32 ) -> i32

source

pub unsafe fn SetLayerPaletteEntries( &self, hdc: *const c_void, iLayerPlane: i32, iStart: i32, cEntries: i32, pcr: *const u32 ) -> i32

source

pub unsafe fn ShareLists( &self, hrcSrvShare: *const c_void, hrcSrvSource: *const c_void ) -> i32

source

pub unsafe fn SwapIntervalEXT(&self, interval: i32) -> i32

source

pub unsafe fn SwapLayerBuffers(&self, hdc: *const c_void, fuFlags: u32) -> i32

source

pub unsafe fn UseFontBitmaps( &self, hDC: *const c_void, first: u32, count: u32, listBase: u32 ) -> i32

source

pub unsafe fn UseFontBitmapsA( &self, hDC: *const c_void, first: u32, count: u32, listBase: u32 ) -> i32

source

pub unsafe fn UseFontBitmapsW( &self, hDC: *const c_void, first: u32, count: u32, listBase: u32 ) -> i32

source

pub unsafe fn UseFontOutlines( &self, hDC: *const c_void, first: u32, count: u32, listBase: u32, deviation: f32, extrusion: f32, format: i32, lpgmf: *const GLYPHMETRICSFLOAT ) -> i32

source

pub unsafe fn UseFontOutlinesA( &self, hDC: *const c_void, first: u32, count: u32, listBase: u32, deviation: f32, extrusion: f32, format: i32, lpgmf: *const GLYPHMETRICSFLOAT ) -> i32

source

pub unsafe fn UseFontOutlinesW( &self, hDC: *const c_void, first: u32, count: u32, listBase: u32, deviation: f32, extrusion: f32, format: i32, lpgmf: *const GLYPHMETRICSFLOAT ) -> i32

Trait Implementations§

source§

impl Clone for Wgl

source§

fn clone(&self) -> Wgl

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Send for Wgl

Auto Trait Implementations§

§

impl RefUnwindSafe for Wgl

§

impl !Sync for Wgl

§

impl Unpin for Wgl

§

impl UnwindSafe for Wgl

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

const: unstable · source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

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

const: unstable · 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> ToOwned for Twhere T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

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

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.
source§

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

§

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

The type returned in the event of a conversion error.
const: unstable · source§

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

Performs the conversion.