Struct rgb::alt::BGR [] [src]

#[repr(C)]
pub struct BGR<ComponentType> { pub b: ComponentType, pub g: ComponentType, pub r: ComponentType, }

RGB in reverse byte order

Fields

Blue first

Green

Red last

Methods

impl<T: Clone> BGR<T>
[src]

[src]

Convenience function for creating a new pixel

[src]

Iterate over color components (R, G, and B)

[src]

[src]

Trait Implementations

impl<T: Copy, B> ComponentMap<BGR<B>, T, B> for BGR<T>
[src]

[src]

Convenience function (equivalent of self.iter().map().collect()) for applying the same formula to every component. Read more

impl<T> ComponentSlice<T> for BGR<T>
[src]

[src]

The components interpreted as an array, e.g. one RGB expands to 3 elements. Read more

[src]

impl<T: Display> Display for BGR<T>
[src]

[src]

Formats the value using the given formatter. Read more

impl<T: Copy> From<BGR<T>> for BGRA<T, u8>
[src]

Assumes 255 is opaque

[src]

Performs the conversion.

impl<T: Copy> From<BGR<T>> for RGBA<T, u8>
[src]

Assumes 255 is opaque

[src]

Performs the conversion.

impl<T: Copy> From<BGR<T>> for BGRA<T, u16>
[src]

Assumes 65535 is opaque

[src]

Performs the conversion.

impl<T: Copy> From<BGR<T>> for RGBA<T, u16>
[src]

Assumes 255 is opaque

[src]

Performs the conversion.

impl<T> From<(T, T, T)> for BGR<T>
[src]

[src]

Performs the conversion.

impl<T> Into<(T, T, T)> for BGR<T>
[src]

[src]

Performs the conversion.

impl<T> From<RGB<T>> for BGR<T>
[src]

[src]

Performs the conversion.

impl<T> From<BGR<T>> for RGB<T>
[src]

[src]

Performs the conversion.

impl<ComponentType: Copy> Copy for BGR<ComponentType>
[src]

impl<ComponentType: Clone> Clone for BGR<ComponentType>
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl<ComponentType: Debug> Debug for BGR<ComponentType>
[src]

[src]

Formats the value using the given formatter. Read more

impl<ComponentType: Default> Default for BGR<ComponentType>
[src]

[src]

Returns the "default value" for a type. Read more

impl<ComponentType: Eq> Eq for BGR<ComponentType>
[src]

impl<ComponentType: PartialEq> PartialEq for BGR<ComponentType>
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.

impl<ComponentType: Ord> Ord for BGR<ComponentType>
[src]

[src]

This method returns an Ordering between self and other. Read more

1.21.0
[src]

Compares and returns the maximum of two values. Read more

1.21.0
[src]

Compares and returns the minimum of two values. Read more

impl<ComponentType: PartialOrd> PartialOrd for BGR<ComponentType>
[src]

[src]

This method returns an ordering between self and other values if one exists. Read more

[src]

This method tests less than (for self and other) and is used by the < operator. Read more

[src]

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

[src]

This method tests greater than (for self and other) and is used by the > operator. Read more

[src]

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl<ComponentType: Hash> Hash for BGR<ComponentType>
[src]

[src]

Feeds this value into the given [Hasher]. Read more

1.3.0
[src]

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

Auto Trait Implementations

impl<ComponentType> Send for BGR<ComponentType> where
    ComponentType: Send

impl<ComponentType> Sync for BGR<ComponentType> where
    ComponentType: Sync