pub struct ShapeMaskNode {
pub mask_rgba: Vec<u8>,
pub mask_width: u32,
pub mask_height: u32,
/* private fields */
}Expand description
Mask inputs[0] using the alpha channel of inputs[1] (or mask_rgba).
Pixels where the mask alpha is > 0 are kept opaque; all others are made fully transparent (hard threshold at ~1/255).
Fields§
§mask_rgba: Vec<u8>Mask frame RGBA bytes (required for the CPU path).
mask_width: u32Width of mask_rgba.
mask_height: u32Height of mask_rgba.
Implementations§
Trait Implementations§
Source§impl RenderNode for ShapeMaskNode
Available on crate feature wgpu only.
impl RenderNode for ShapeMaskNode
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 ShapeMaskNode
impl RenderNodeCpu for ShapeMaskNode
Auto Trait Implementations§
impl !Freeze for ShapeMaskNode
impl !RefUnwindSafe for ShapeMaskNode
impl !UnwindSafe for ShapeMaskNode
impl Send for ShapeMaskNode
impl Sync for ShapeMaskNode
impl Unpin for ShapeMaskNode
impl UnsafeUnpin for ShapeMaskNode
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