pub struct PresentBuilder<B: Backend> { /* private fields */ }
Expand description
Presentation node description.
Implementations§
Source§impl<B> PresentBuilder<B>where
B: Backend,
impl<B> PresentBuilder<B>where
B: Backend,
Sourcepub fn add_dependency(&mut self, dependency: NodeId) -> &mut Self
pub fn add_dependency(&mut self, dependency: NodeId) -> &mut Self
Add dependency. Node will be placed after its dependencies.
Sourcepub fn with_dependency(self, dependency: NodeId) -> Self
pub fn with_dependency(self, dependency: NodeId) -> Self
Add dependency. Node will be placed after its dependencies.
Sourcepub fn with_image_count(self, image_count: u32) -> Self
pub fn with_image_count(self, image_count: u32) -> Self
Request a number of images in the swapchain. This is not guaranteed to be the final image count, but it will be if supported by the hardware.
Check PresentBuilder::image_count()
after calling this function but before
building to see the final image count.
Sourcepub fn with_blit_filter(self, filter: Filter) -> Self
pub fn with_blit_filter(self, filter: Filter) -> Self
Set up filter used for resizing when backbuffer size does not match source image size.
Default is Nearest
.
Sourcepub fn with_present_modes_priority<PF>(self, present_modes_priority: PF) -> Self
pub fn with_present_modes_priority<PF>(self, present_modes_priority: PF) -> Self
Request a priority of present modes when creating the swapchain for the PresentNode. Lower index means higher priority.
Check PresentBuilder::present_mode()
after calling this function but before
building to see the final present mode.
§Parameters
- present_modes_priority: A function which takes a
rendy_core::hal::PresentMode
and returns anOption<usize>
.None
indicates not to use this mode, and a higher number returned indicates a higher prioirity for that mode.
§Panics
- Panics if none of the provided
PresentMode
s are supported.
Sourcepub fn image_count(&self) -> u32
pub fn image_count(&self) -> u32
Get image count in presentable swapchain.
Sourcepub fn present_mode(&self) -> PresentMode
pub fn present_mode(&self) -> PresentMode
Get present mode used by node.
Trait Implementations§
Auto Trait Implementations§
impl<B> Freeze for PresentBuilder<B>
impl<B> RefUnwindSafe for PresentBuilder<B>
impl<B> Send for PresentBuilder<B>
impl<B> Sync for PresentBuilder<B>
impl<B> Unpin for PresentBuilder<B>
impl<B> UnwindSafe for PresentBuilder<B>
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> 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