pub struct St2086Codes(/* private fields */);Expand description
Full re-export of zenpixels core types (zero module name collisions!).
Exact mastering-display codes, separate from the lossy floating-point view.
Chromaticities are in units of 0.00002; luminances in units of 0.0001 cd/m².
Byte serialization uses RGB primary order, then white, maximum and minimum
luminance, all big-endian. Adapters for formats with another primary order
must reorder explicitly. No validation discards unknown or out-of-range codes.
Implementations§
Source§impl St2086Codes
impl St2086Codes
Sourcepub const fn from_rgb_order_be_bytes(bytes: [u8; 24]) -> St2086Codes
pub const fn from_rgb_order_be_bytes(bytes: [u8; 24]) -> St2086Codes
Preserve all 24 big-endian bytes in RGB primary order ([Rx, Ry, Gx, Gy, Bx, By, Wx, Wy, max, min]).
Note: container wire formats using ST 2086 G,B,R primary order (e.g. HEVC/AV1/PNG mDCV)
must reorder to RGB before calling this constructor.
Sourcepub const fn to_rgb_order_be_bytes(self) -> [u8; 24]
pub const fn to_rgb_order_be_bytes(self) -> [u8; 24]
Return the exact 24 big-endian bytes in RGB primary order, without a float round trip.
Sourcepub fn semantic(self) -> MasteringDisplay
pub fn semantic(self) -> MasteringDisplay
Interpret codes for display decisions. This view can lose precision; retain this carrier when exact metadata must survive a transcode.
Trait Implementations§
Source§impl Clone for St2086Codes
impl Clone for St2086Codes
Source§fn clone(&self) -> St2086Codes
fn clone(&self) -> St2086Codes
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more