pub(crate) struct AdvancedBlendPipelines {
pipelines: HashMap<BlendMode, RenderPipeline>,
bind_group_layout: BindGroupLayout,
sampler: Sampler,
}Expand description
Cache of one [wgpu::RenderPipeline] per advanced BlendMode.
Fields§
§pipelines: HashMap<BlendMode, RenderPipeline>§bind_group_layout: BindGroupLayout§sampler: SamplerImplementations§
Source§impl AdvancedBlendPipelines
impl AdvancedBlendPipelines
pub(crate) fn new(app: &Application, output_format: TextureFormat) -> Self
Sourcepub(crate) fn apply(
&self,
app: &Application,
mode: BlendMode,
backdrop: &RenderTexture,
foreground: &RenderTexture,
output: &RenderTexture,
)
pub(crate) fn apply( &self, app: &Application, mode: BlendMode, backdrop: &RenderTexture, foreground: &RenderTexture, output: &RenderTexture, )
Compose backdrop + foreground via mode’s blend function,
writing the result into output. All three render-textures must
share the same dimensions.
Auto Trait Implementations§
impl Freeze for AdvancedBlendPipelines
impl !RefUnwindSafe for AdvancedBlendPipelines
impl Send for AdvancedBlendPipelines
impl Sync for AdvancedBlendPipelines
impl Unpin for AdvancedBlendPipelines
impl UnsafeUnpin for AdvancedBlendPipelines
impl !UnwindSafe for AdvancedBlendPipelines
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> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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>
Converts
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>
Converts
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