Struct screen_13::driver::swapchain::SwapchainInfoBuilder
source · pub struct SwapchainInfoBuilder { /* private fields */ }
Expand description
Builder for SwapchainInfo
.
Implementations§
source§impl SwapchainInfoBuilder
impl SwapchainInfoBuilder
sourcepub fn desired_image_count(self, value: u32) -> Self
pub fn desired_image_count(self, value: u32) -> Self
The desired, but not guaranteed, number of images that will be in the created swapchain.
More images introduces more display lag, but smoother animation.
sourcepub fn surface(self, value: SurfaceFormatKHR) -> Self
pub fn surface(self, value: SurfaceFormatKHR) -> Self
The format and color space of the surface.
sourcepub fn sync_display(self, value: bool) -> Self
pub fn sync_display(self, value: bool) -> Self
Determines if frames will be submitted to the display in a synchronous fashion or if they should be displayed as fast as possible instead.
Turn on to eliminate visual tearing at the expense of latency.
source§impl SwapchainInfoBuilder
impl SwapchainInfoBuilder
sourcepub fn build(self) -> SwapchainInfo
pub fn build(self) -> SwapchainInfo
Builds a new SwapchainInfo
.
§Panics
If any of the following values have not been set this function will panic:
width
height
surface
Trait Implementations§
source§impl Clone for SwapchainInfoBuilder
impl Clone for SwapchainInfoBuilder
source§fn clone(&self) -> SwapchainInfoBuilder
fn clone(&self) -> SwapchainInfoBuilder
Returns a copy of the value. Read more
1.0.0 · 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 SwapchainInfoBuilder
impl Debug for SwapchainInfoBuilder
source§impl Default for SwapchainInfoBuilder
impl Default for SwapchainInfoBuilder
source§impl From<SwapchainInfoBuilder> for SwapchainInfo
impl From<SwapchainInfoBuilder> for SwapchainInfo
source§fn from(info: SwapchainInfoBuilder) -> Self
fn from(info: SwapchainInfoBuilder) -> Self
Converts to this type from the input type.
impl Copy for SwapchainInfoBuilder
Auto Trait Implementations§
impl RefUnwindSafe for SwapchainInfoBuilder
impl Send for SwapchainInfoBuilder
impl Sync for SwapchainInfoBuilder
impl Unpin for SwapchainInfoBuilder
impl UnwindSafe for SwapchainInfoBuilder
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.