pub struct HwRenderConfig {
pub context_type: HwContextType,
pub depth: bool,
pub stencil: bool,
pub bottom_left_origin: bool,
pub version_major: u32,
pub version_minor: u32,
pub cache_context: bool,
pub debug_context: bool,
}Expand description
Hardware-rendering context request sent to the frontend.
Use the constructors such as HwRenderConfig::opengl_core or the candidate
helpers in hw_render instead of filling raw context IDs manually.
Fields§
§context_type: HwContextType§depth: bool§stencil: bool§bottom_left_origin: bool§version_major: u32§version_minor: u32§cache_context: bool§debug_context: boolImplementations§
Source§impl HwRenderConfig
impl HwRenderConfig
pub fn new(context_type: HwContextType) -> Self
pub fn opengl() -> Self
pub fn opengl_core(version_major: u32, version_minor: u32) -> Self
pub fn opengles2() -> Self
pub fn opengles3() -> Self
pub fn opengles_version(version_major: u32, version_minor: u32) -> Self
pub fn with_depth(self, depth: bool) -> Self
pub fn with_stencil(self, stencil: bool) -> Self
pub fn with_bottom_left_origin(self, bottom_left_origin: bool) -> Self
pub fn with_version(self, version_major: u32, version_minor: u32) -> Self
pub fn with_cache_context(self, cache_context: bool) -> Self
pub fn with_debug_context(self, debug_context: bool) -> Self
Trait Implementations§
Source§impl Clone for HwRenderConfig
impl Clone for HwRenderConfig
Source§fn clone(&self) -> HwRenderConfig
fn clone(&self) -> HwRenderConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HwRenderConfig
impl Debug for HwRenderConfig
Source§impl Default for HwRenderConfig
impl Default for HwRenderConfig
Source§fn default() -> HwRenderConfig
fn default() -> HwRenderConfig
Returns the “default value” for a type. Read more
Source§impl PartialEq for HwRenderConfig
impl PartialEq for HwRenderConfig
Source§fn eq(&self, other: &HwRenderConfig) -> bool
fn eq(&self, other: &HwRenderConfig) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for HwRenderConfig
impl Eq for HwRenderConfig
impl StructuralPartialEq for HwRenderConfig
Auto Trait Implementations§
impl Freeze for HwRenderConfig
impl RefUnwindSafe for HwRenderConfig
impl Send for HwRenderConfig
impl Sync for HwRenderConfig
impl Unpin for HwRenderConfig
impl UnsafeUnpin for HwRenderConfig
impl UnwindSafe for HwRenderConfig
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