Type Alias freya_engine::prelude::ImageInfo

pub type ImageInfo = Handle<SkImageInfo>;

Aliased Type§

struct ImageInfo(/* private fields */);

Implementations

§

impl Handle<SkImageInfo>

pub fn new( dimensions: impl Into<ISize>, ct: ColorType, at: SkAlphaType, cs: impl Into<Option<RCHandle<SkColorSpace>>>, ) -> Handle<SkImageInfo>

pub fn from_color_info( dimensions: impl Into<ISize>, color_info: Handle<SkColorInfo>, ) -> Handle<SkImageInfo>

pub fn new_n32( dimensions: impl Into<ISize>, at: SkAlphaType, cs: impl Into<Option<RCHandle<SkColorSpace>>>, ) -> Handle<SkImageInfo>

pub fn new_s32( dimensions: impl Into<ISize>, at: SkAlphaType, ) -> Handle<SkImageInfo>

pub fn new_n32_premul( dimensions: impl Into<ISize>, cs: impl Into<Option<RCHandle<SkColorSpace>>>, ) -> Handle<SkImageInfo>

pub fn new_a8(dimensions: impl Into<ISize>) -> Handle<SkImageInfo>

pub fn new_unknown(dimensions: Option<ISize>) -> Handle<SkImageInfo>

pub fn width(&self) -> i32

pub fn height(&self) -> i32

pub fn color_type(&self) -> ColorType

pub fn alpha_type(&self) -> SkAlphaType

pub fn color_space(&self) -> Option<RCHandle<SkColorSpace>>

pub fn is_empty(&self) -> bool

pub fn color_info(&self) -> &Handle<SkColorInfo>

pub fn is_opaque(&self) -> bool

pub fn dimensions(&self) -> ISize

pub fn bounds(&self) -> IRect

pub fn is_gamma_close_to_srgb(&self) -> bool

pub fn with_dimensions( &self, new_dimensions: impl Into<ISize>, ) -> Handle<SkImageInfo>

pub fn with_alpha_type( &self, new_alpha_type: SkAlphaType, ) -> Handle<SkImageInfo>

pub fn with_color_type(&self, new_color_type: ColorType) -> Handle<SkImageInfo>

pub fn with_color_space( &self, new_color_space: impl Into<Option<RCHandle<SkColorSpace>>>, ) -> Handle<SkImageInfo>

pub fn bytes_per_pixel(&self) -> usize

pub fn shift_per_pixel(&self) -> usize

pub fn min_row_bytes(&self) -> usize

pub fn compute_offset( &self, point: impl Into<IPoint>, row_bytes: usize, ) -> usize

pub fn compute_byte_size(&self, row_bytes: usize) -> usize

pub fn compute_min_byte_size(&self) -> usize

pub fn valid_row_bytes(&self, row_bytes: usize) -> bool

pub fn reset(&mut self) -> &mut Handle<SkImageInfo>

Trait Implementations

§

impl<N> AsRef<Handle<N>> for Handle<N>
where N: NativeDrop,

§

fn as_ref(&self) -> &Handle<N>

Converts this type into a shared reference of the (usually inferred) input type.
§

impl<N> Clone for Handle<N>
where N: NativeDrop + NativeClone,

§

fn clone(&self) -> Handle<N>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl Debug for Handle<SkImageInfo>

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl Default for Handle<SkImageInfo>

§

fn default() -> Handle<SkImageInfo>

Returns the “default value” for a type. Read more
§

impl<N> Drop for Handle<N>
where N: NativeDrop,

§

fn drop(&mut self)

Executes the destructor for this type. Read more
§

impl<N> Hash for Handle<N>
where N: NativeDrop + NativeHash,

§

fn hash<H>(&self, state: &mut H)
where H: Hasher,

Feeds this value into the given Hasher. Read more
1.3.0 · source§

fn hash_slice<H>(data: &[Self], state: &mut H)
where H: Hasher, Self: Sized,

Feeds a slice of this type into the given Hasher. Read more
§

impl<N> PartialEq for Handle<N>
where N: NativeDrop + NativePartialEq,

§

fn eq(&self, rhs: &Handle<N>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl<N> RefWrapper<N> for Handle<N>
where N: NativeDrop,

§

fn wrap_ref(native: &N) -> &Handle<N>

§

fn wrap_mut(native: &mut N) -> &mut Handle<N>

§

fn inner(&self) -> &N

§

fn inner_mut(&mut self) -> &mut N

§

impl<N> ValueWrapper<N> for Handle<N>
where N: NativeDrop,

§

fn wrap(native: N) -> Handle<N>
where N: NativeDrop,

§

fn unwrap(self) -> N

§

fn inner(&self) -> &N

§

fn inner_mut(&mut self) -> &mut N

§

impl Send for Handle<SkImageInfo>

§

impl Sync for Handle<SkImageInfo>