#[repr(C)]
pub enum ColorSpace {
JCS_UNKNOWN,
JCS_GRAYSCALE,
JCS_RGB,
JCS_YCbCr,
JCS_CMYK,
JCS_YCCK,
JCS_EXT_RGB,
JCS_EXT_RGBX,
JCS_EXT_BGR,
JCS_EXT_BGRX,
JCS_EXT_XBGR,
JCS_EXT_XRGB,
JCS_EXT_RGBA,
JCS_EXT_BGRA,
JCS_EXT_ABGR,
JCS_EXT_ARGB,
JCS_RGB565,
}
red/green/blue as specified by the RGB_RED, RGB_GREEN, RGB_BLUE, and RGB_PIXELSIZE macros
Y/Cb/Cr (also known as YUV)
red/green/blue/x
When out_color_space it set to JCS_EXT_RGBX, JCS_EXT_BGRX, JCS_EXT_XBGR,
or JCS_EXT_XRGB during decompression, the X byte is undefined, and in
order to ensure the best performance, libjpeg-turbo can set that byte to
whatever value it wishes.
Use the following colorspace constants to
ensure that the X byte is set to 0xFF, so that it can be interpreted as an
opaque alpha channel.
red/green/blue/alpha
5-bit red/6-bit green/5-bit blue
Formats the value using the given formatter. Read more
Performs copy-assignment from source
. Read more
This method tests for self
and other
values to be equal, and is used by ==
. Read more
This method tests for !=
.
Number of channels (including unused alpha) in this color space
Creates owned data from borrowed data, usually by cloning. Read more
🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static