pub enum TransferFunction {
Srgb,
Linear,
Bt709,
}Expand description
How a buffer’s stored values relate to light intensity.
Independent of YuvRange (where structural black and white sit in the integers) and of the
layout dimensions SurfaceFormatKind carries: the same bytes can be sRGB-encoded or linear, and
the range is a separate axis again.
The default for an RGB buffer is Srgb — desktop buffers, screen capture and UI
assets are sRGB-encoded — and for a YCbCr one Bt709, whose matrix already
produces non-linear R'G'B'. Linear is what a 3D engine’s linear render target
carries; the renderer encodes it before compositing.
Variants§
Srgb
sRGB-encoded (IEC 61966-2-1): the default for 8-bit RGB.
Linear
Linear light: what an engine’s render target holds before any display encoding.
Bt709
The BT.709 curve (BT.601 shares it): YCbCr video’s non-linear R'G'B'.
Trait Implementations§
Source§impl Clone for TransferFunction
impl Clone for TransferFunction
impl Copy for TransferFunction
Source§impl Debug for TransferFunction
impl Debug for TransferFunction
Source§impl Default for TransferFunction
impl Default for TransferFunction
impl Eq for TransferFunction
Source§impl PartialEq for TransferFunction
impl PartialEq for TransferFunction
impl StructuralPartialEq for TransferFunction
Auto Trait Implementations§
impl Freeze for TransferFunction
impl RefUnwindSafe for TransferFunction
impl Send for TransferFunction
impl Sync for TransferFunction
impl Unpin for TransferFunction
impl UnsafeUnpin for TransferFunction
impl UnwindSafe for TransferFunction
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.