#[non_exhaustive]pub struct RendererConfig {
pub base_color: Option<Color>,
pub composite_alpha_mode: Option<CompositeAlphaMode>,
}Expand description
Unified renderer configuration options.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.base_color: Option<Color>Background color used to clear the frame.
composite_alpha_mode: Option<CompositeAlphaMode>Alpha mode used when compositing the window surface.
Implementations§
Source§impl RendererConfig
impl RendererConfig
Sourcepub const fn base_color(self, base_color: Color) -> Self
pub const fn base_color(self, base_color: Color) -> Self
Set the background color.
Sourcepub const fn composite_alpha_mode(self, mode: CompositeAlphaMode) -> Self
pub const fn composite_alpha_mode(self, mode: CompositeAlphaMode) -> Self
Set the composite alpha mode.
Trait Implementations§
Source§impl Clone for RendererConfig
impl Clone for RendererConfig
Source§fn clone(&self) -> RendererConfig
fn clone(&self) -> RendererConfig
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 RendererConfig
impl Debug for RendererConfig
Source§impl Default for RendererConfig
impl Default for RendererConfig
Source§fn default() -> RendererConfig
fn default() -> RendererConfig
Returns the “default value” for a type. Read more
Source§impl PartialEq for RendererConfig
impl PartialEq for RendererConfig
impl StructuralPartialEq for RendererConfig
Auto Trait Implementations§
impl Freeze for RendererConfig
impl RefUnwindSafe for RendererConfig
impl Send for RendererConfig
impl Sync for RendererConfig
impl Unpin for RendererConfig
impl UnsafeUnpin for RendererConfig
impl UnwindSafe for RendererConfig
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