pub struct GlBackendOptions {
pub gles_minor_version: Gles3MinorVersion,
pub fence_behavior: GlFenceBehavior,
pub debug_fns: GlDebugFns,
}Expand description
Configuration for the OpenGL/OpenGLES backend.
Part of BackendOptions.
Fields§
§gles_minor_version: Gles3MinorVersionWhich OpenGL ES 3 minor version to request, if using OpenGL ES.
fence_behavior: GlFenceBehaviorBehavior of OpenGL fences. Affects how on_completed_work_done and device.poll behave.
debug_fns: GlDebugFnsControls whether debug functions (glPushDebugGroup, glPopDebugGroup,
glObjectLabel, etc.) are enabled when supported by the driver.
By default (GlDebugFns::Auto), debug functions are automatically
disabled on devices with known bugs (e.g., Mali GPUs can crash in
glPushDebugGroup). Use GlDebugFns::ForceEnabled to override this
behavior, or GlDebugFns::Disabled to disable debug functions entirely.
See also InstanceFlags::DISCARD_HAL_LABELS, which prevents debug
markers and labels from being sent to any backend, but without the
driver-specific bug workarounds provided here.
Implementations§
Source§impl GlBackendOptions
impl GlBackendOptions
Sourcepub fn from_env_or_default() -> Self
pub fn from_env_or_default() -> Self
Choose OpenGL backend options by calling from_env on every field.
See those methods for more information.
Trait Implementations§
Source§impl Clone for GlBackendOptions
impl Clone for GlBackendOptions
Source§fn clone(&self) -> GlBackendOptions
fn clone(&self) -> GlBackendOptions
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for GlBackendOptions
impl Debug for GlBackendOptions
Source§impl Default for GlBackendOptions
impl Default for GlBackendOptions
Source§fn default() -> GlBackendOptions
fn default() -> GlBackendOptions
Auto Trait Implementations§
impl Freeze for GlBackendOptions
impl RefUnwindSafe for GlBackendOptions
impl Send for GlBackendOptions
impl Sync for GlBackendOptions
impl Unpin for GlBackendOptions
impl UnwindSafe for GlBackendOptions
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more