pub struct AlphaMatteNode {
pub background_rgba: Vec<u8>,
pub background_width: u32,
pub background_height: u32,
/* private fields */
}Expand description
Porter-Duff src-over: composite inputs[0] (foreground) over inputs[1]
(background) using the foreground’s own alpha channel.
For the CPU path the background data must be stored in background_rgba.
Fields§
§background_rgba: Vec<u8>Background frame RGBA bytes (required for the CPU path).
background_width: u32Width of background_rgba.
background_height: u32Height of background_rgba.
Implementations§
Trait Implementations§
Source§impl RenderNode for AlphaMatteNode
Available on crate feature wgpu only.
impl RenderNode for AlphaMatteNode
Available on crate feature
wgpu only.Source§fn input_count(&self) -> usize
fn input_count(&self) -> usize
Number of input textures required by this node (default: 1).
Source§fn process(
&self,
inputs: &[&Texture],
outputs: &[&Texture],
ctx: &RenderContext,
)
fn process( &self, inputs: &[&Texture], outputs: &[&Texture], ctx: &RenderContext, )
Run the GPU render pass. Read more
Source§fn pass_count(&self) -> usize
fn pass_count(&self) -> usize
Number of render passes (default: 1). Multi-pass nodes (e.g. gaussian
blur) return 2 or more.
Source§impl RenderNodeCpu for AlphaMatteNode
impl RenderNodeCpu for AlphaMatteNode
Auto Trait Implementations§
impl !Freeze for AlphaMatteNode
impl !RefUnwindSafe for AlphaMatteNode
impl !UnwindSafe for AlphaMatteNode
impl Send for AlphaMatteNode
impl Sync for AlphaMatteNode
impl Unpin for AlphaMatteNode
impl UnsafeUnpin for AlphaMatteNode
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