pub struct ImageScaleAndAdd { /* private fields */ }Expand description
Convenience wrapper for scale-and-add semantics implemented with MPSImageAdd.
Implementations§
Source§impl ImageScaleAndAdd
impl ImageScaleAndAdd
Sourcepub fn new(
device: &MetalDevice,
primary_scale: f32,
secondary_scale: f32,
bias: f32,
) -> Option<Self>
pub fn new( device: &MetalDevice, primary_scale: f32, secondary_scale: f32, bias: f32, ) -> Option<Self>
Build an image add kernel with non-unit primary/secondary scales.
pub const fn as_ptr(&self) -> *mut c_void
pub fn encode_image( &self, command_buffer: &CommandBuffer, primary: &Image, secondary: &Image, destination: &Image, )
pub fn encode_texture( &self, command_buffer: &CommandBuffer, primary: &MetalTexture, secondary: &MetalTexture, destination: &MetalTexture, )
pub fn set_primary_edge_mode(&self, edge_mode: usize)
pub fn set_secondary_edge_mode(&self, edge_mode: usize)
pub fn set_clip_rect(&self, region: ImageRegion)
pub fn set_clamp(&self, minimum_value: f32, maximum_value: f32)
Auto Trait Implementations§
impl Freeze for ImageScaleAndAdd
impl RefUnwindSafe for ImageScaleAndAdd
impl Send for ImageScaleAndAdd
impl Sync for ImageScaleAndAdd
impl Unpin for ImageScaleAndAdd
impl UnsafeUnpin for ImageScaleAndAdd
impl UnwindSafe for ImageScaleAndAdd
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