#[repr(i32)]pub enum MemoryFormat {
Show 23 variants
B8g8r8a8Premultiplied = 0,
A8r8g8b8Premultiplied = 1,
R8g8b8a8Premultiplied = 2,
B8g8r8a8 = 3,
A8r8g8b8 = 4,
R8g8b8a8 = 5,
A8b8g8r8 = 6,
R8g8b8 = 7,
B8g8r8 = 8,
R16g16b16 = 9,
R16g16b16a16Premultiplied = 10,
R16g16b16a16 = 11,
R16g16b16Float = 12,
R16g16b16a16Float = 13,
R32g32b32Float = 14,
R32g32b32a32FloatPremultiplied = 15,
R32g32b32a32Float = 16,
G8a8Premultiplied = 17,
G8a8 = 18,
G8 = 19,
G16a16Premultiplied = 20,
G16a16 = 21,
G16 = 22,
}
Expand description
Describes the formats the image data can have.
Variants§
B8g8r8a8Premultiplied = 0
A8r8g8b8Premultiplied = 1
R8g8b8a8Premultiplied = 2
B8g8r8a8 = 3
A8r8g8b8 = 4
R8g8b8a8 = 5
A8b8g8r8 = 6
R8g8b8 = 7
B8g8r8 = 8
R16g16b16 = 9
R16g16b16a16Premultiplied = 10
R16g16b16a16 = 11
R16g16b16Float = 12
R16g16b16a16Float = 13
R32g32b32Float = 14
R32g32b32a32FloatPremultiplied = 15
R32g32b32a32Float = 16
G8a8Premultiplied = 17
G8a8 = 18
G8 = 19
G16a16Premultiplied = 20
G16a16 = 21
G16 = 22
Implementations§
Source§impl MemoryFormat
impl MemoryFormat
pub fn to_color_type(&self) -> Option<ColorType>
Available on crate feature
image-rs
only.Source§impl MemoryFormat
impl MemoryFormat
Trait Implementations§
Source§impl Clone for MemoryFormat
impl Clone for MemoryFormat
Source§fn clone(&self) -> MemoryFormat
fn clone(&self) -> MemoryFormat
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MemoryFormat
impl Debug for MemoryFormat
Source§impl<'de> Deserialize<'de> for MemoryFormat
impl<'de> Deserialize<'de> for MemoryFormat
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<ColorType> for MemoryFormat
Available on crate feature image-rs
only.
impl From<ColorType> for MemoryFormat
Available on crate feature
image-rs
only.Source§impl From<MemoryFormat> for ExtendedMemoryFormat
impl From<MemoryFormat> for ExtendedMemoryFormat
Source§fn from(value: MemoryFormat) -> Self
fn from(value: MemoryFormat) -> Self
Converts to this type from the input type.
Source§impl From<MemoryFormat> for Value
impl From<MemoryFormat> for Value
Source§fn from(v: MemoryFormat) -> Self
fn from(v: MemoryFormat) -> Self
Converts to this type from the input type.
Source§impl From<MemoryFormat> for i32
Convert enum to it’s discriminant value
impl From<MemoryFormat> for i32
Convert enum to it’s discriminant value
Source§fn from(v: MemoryFormat) -> i32
fn from(v: MemoryFormat) -> i32
Converts to this type from the input type.
Source§impl<'a> FromValue<'a> for MemoryFormat
impl<'a> FromValue<'a> for MemoryFormat
Source§type Checker = GenericValueTypeChecker<MemoryFormat>
type Checker = GenericValueTypeChecker<MemoryFormat>
Value type checker.
Source§unsafe fn from_value(value: &'a Value) -> Self
unsafe fn from_value(value: &'a Value) -> Self
Get the contained value from a
Value
. Read moreSource§impl HasParamSpec for MemoryFormat
impl HasParamSpec for MemoryFormat
type ParamSpec = ParamSpecEnum
Source§type SetValue = MemoryFormat
type SetValue = MemoryFormat
Preferred value to be used as setter for the associated ParamSpec.
type BuilderFn = fn(&str, MemoryFormat) -> ParamSpecEnumBuilder<'_, MemoryFormat>
fn param_spec_builder() -> Self::BuilderFn
Source§impl MemoryFormatInfo for MemoryFormat
impl MemoryFormatInfo for MemoryFormat
fn n_bytes(self) -> MemoryFormatBytes
fn n_channels(self) -> u8
Source§impl Serialize for MemoryFormat
impl Serialize for MemoryFormat
Source§impl StaticType for MemoryFormat
impl StaticType for MemoryFormat
Source§fn static_type() -> Type
fn static_type() -> Type
Returns the type identifier of
Self
.Source§impl ToValue for MemoryFormat
impl ToValue for MemoryFormat
Source§impl TryFrom<i32> for MemoryFormat
Create enum from it’s discriminant value
impl TryFrom<i32> for MemoryFormat
Create enum from it’s discriminant value
Source§impl TryFromGlib<i32> for MemoryFormat
impl TryFromGlib<i32> for MemoryFormat
Source§impl Type for MemoryFormat
impl Type for MemoryFormat
Source§impl ValueType for MemoryFormat
impl ValueType for MemoryFormat
Source§type Type = MemoryFormat
type Type = MemoryFormat
Type to get the
Type
from. Read moreimpl Copy for MemoryFormat
Auto Trait Implementations§
impl Freeze for MemoryFormat
impl RefUnwindSafe for MemoryFormat
impl Send for MemoryFormat
impl Sync for MemoryFormat
impl Unpin for MemoryFormat
impl UnwindSafe for MemoryFormat
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<'de, T> DynamicDeserialize<'de> for Twhere
T: Type + Deserialize<'de>,
impl<'de, T> DynamicDeserialize<'de> for Twhere
T: Type + Deserialize<'de>,
Source§type Deserializer = PhantomData<T>
type Deserializer = PhantomData<T>
A DeserializeSeed implementation for this type.
Source§fn deserializer_for_signature(
signature: &Signature,
) -> Result<<T as DynamicDeserialize<'de>>::Deserializer, Error>
fn deserializer_for_signature( signature: &Signature, ) -> Result<<T as DynamicDeserialize<'de>>::Deserializer, Error>
Get a deserializer compatible with this parsed signature.
Source§impl<T> DynamicType for T
impl<T> DynamicType for T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoClosureReturnValue for T
impl<T> IntoClosureReturnValue for T
fn into_closure_return_value(self) -> Option<Value>
Source§impl<T> PropertyGet for Twhere
T: HasParamSpec,
impl<T> PropertyGet for Twhere
T: HasParamSpec,
Source§impl<T> StaticTypeExt for Twhere
T: StaticType,
impl<T> StaticTypeExt for Twhere
T: StaticType,
Source§fn ensure_type()
fn ensure_type()
Ensures that the type has been registered with the type system.
Source§impl<T> ToSendValue for T
impl<T> ToSendValue for T
Source§fn to_send_value(&self) -> SendValue
fn to_send_value(&self) -> SendValue
Returns a
SendValue
clone of self
.