Struct CGImage
pub struct CGImage { /* private fields */ }Expand description
Reference-counted CGImageRef — an immutable bitmap.
Implementations§
§impl CGImage
impl CGImage
pub fn bits_per_component(&self) -> usize
pub fn bits_per_component(&self) -> usize
Bits per component (8, 16, 32).
pub fn bits_per_pixel(&self) -> usize
pub fn bits_per_pixel(&self) -> usize
Bits per pixel.
pub fn bytes_per_row(&self) -> usize
pub fn bytes_per_row(&self) -> usize
Bytes per row.
Trait Implementations§
Source§impl CGImageExt for CGImage
impl CGImageExt for CGImage
Source§fn rgba_data_into(&self, dest: &mut [u8]) -> Result<usize, SCError>
fn rgba_data_into(&self, dest: &mut [u8]) -> Result<usize, SCError>
Render the image’s RGBA bytes into a caller-supplied buffer. Read more
Source§fn bgra_data_into(&self, dest: &mut [u8]) -> Result<usize, SCError>
fn bgra_data_into(&self, dest: &mut [u8]) -> Result<usize, SCError>
Render the image’s BGRA bytes into a caller-supplied buffer. Read more
Source§fn rgba_data_into_strided(
&self,
dest: &mut [u8],
dest_bytes_per_row: usize,
) -> Result<usize, SCError>
fn rgba_data_into_strided( &self, dest: &mut [u8], dest_bytes_per_row: usize, ) -> Result<usize, SCError>
Render the image’s RGBA bytes into a caller-supplied buffer using an
explicit row stride (
dest_bytes_per_row). Read moreimpl Send for CGImage
impl Sync for CGImage
Auto Trait Implementations§
impl Freeze for CGImage
impl RefUnwindSafe for CGImage
impl Unpin for CGImage
impl UnsafeUnpin for CGImage
impl UnwindSafe for CGImage
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