#[repr(C)]pub struct FilterInstanceData {
pub source_origin: u32,
pub source_size: u32,
pub dest_origin: u32,
pub dest_size: u32,
pub dest_texture_size: u32,
pub filter_data_offset: u32,
pub original_size: u32,
pub filter_pass_kind: u32,
}Expand description
One filter pass’s per-instance vertex data.
Must stay byte-compatible with FilterInstanceData in
shaders/filter.wgsl. Every extent is a u16 pair packed into one word,
the same packing the strip and copy instances use.
Fields§
§source_origin: u32Origin of the source region inside the source page.
source_size: u32Extent of the source region.
dest_origin: u32Origin of the destination region inside the destination page.
dest_size: u32Extent of the destination region.
dest_texture_size: u32Extent of the whole destination page.
filter_data_offset: u32Texel offset of this filter’s parameter block in the filter-data texture.
original_size: u32Extent of the filter layer before any decimation, which bounds the transparent border a decimated pass overdraws.
filter_pass_kind: u32Which pass of the filter’s sequence this instance runs, one of
FilterPassKind::code’s values.
Implementations§
Source§impl FilterInstanceData
impl FilterInstanceData
Sourcepub fn new(
step: &FilterStep,
filter_data_offset: u32,
source_origin: (u16, u16),
dest_origin: (u16, u16),
dest_texture_size: SizeU16,
original_size: SizeU16,
) -> Self
pub fn new( step: &FilterStep, filter_data_offset: u32, source_origin: (u16, u16), dest_origin: (u16, u16), dest_texture_size: SizeU16, original_size: SizeU16, ) -> Self
The instance running step of a filter whose parameters start at
filter_data_offset, from source_origin of the source page into
dest_origin of a destination page of dest_texture_size.
original_size is the filter layer’s own extent, before decimation.
Trait Implementations§
Source§impl Clone for FilterInstanceData
impl Clone for FilterInstanceData
impl Copy for FilterInstanceData
Source§impl Debug for FilterInstanceData
impl Debug for FilterInstanceData
Source§impl PartialEq for FilterInstanceData
impl PartialEq for FilterInstanceData
impl Pod for FilterInstanceData
impl StructuralPartialEq for FilterInstanceData
Auto Trait Implementations§
impl Freeze for FilterInstanceData
impl RefUnwindSafe for FilterInstanceData
impl Send for FilterInstanceData
impl Sync for FilterInstanceData
impl Unpin for FilterInstanceData
impl UnsafeUnpin for FilterInstanceData
impl UnwindSafe for FilterInstanceData
Blanket Implementations§
impl<T> AnyBitPattern for Twhere
T: Pod,
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
bits
as &Self.