Enum sixtyfps_corelib::graphics::SharedImageBuffer [−][src]
#[repr(C)]
pub enum SharedImageBuffer {
RGB8(SharedPixelBuffer<Rgb8Pixel>),
RGBA8(SharedPixelBuffer<Rgba8Pixel>),
RGBA8Premultiplied(SharedPixelBuffer<Rgba8Pixel>),
}
Expand description
SharedImageBuffer is a container for images that are stored in CPU accessible memory.
The SharedImageBuffer’s variants represent the different common formats for encoding images in pixels.
Variants
RGB8(SharedPixelBuffer<Rgb8Pixel>)
This variant holds the data for an image where each pixel has three color channels (red, green, and blue) and each channel is encoded as unsigned byte.
Tuple Fields of RGB8
RGBA8(SharedPixelBuffer<Rgba8Pixel>)
This variant holds the data for an image where each pixel has four color channels (red, green, blue and alpha) and each channel is encoded as unsigned byte.
Tuple Fields of RGBA8
RGBA8Premultiplied(SharedPixelBuffer<Rgba8Pixel>)
This variant holds the data for an image where each pixel has four color channels (red, green,
blue and alpha) and each channel is encoded as unsigned byte. In contrast to Self::RGBA8
,
this variant assumes that the alpha channel is also already multiplied to each red, green and blue
component of each pixel.
Only construct this format if you know that your pixels are encoded this way. It is more efficient
for rendering.
Tuple Fields of RGBA8Premultiplied
Implementations
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for SharedImageBuffer
impl !Send for SharedImageBuffer
impl !Sync for SharedImageBuffer
impl Unpin for SharedImageBuffer
impl UnwindSafe for SharedImageBuffer
Blanket Implementations
Mutably borrows from an owned value. Read more