Documentation
¶
Index ¶
- type ChromaSamplePosition
- type ChromaSampling
- func (s ChromaSampling) ElementChromaSamples() int
- func (s ChromaSampling) ElementPixels() int
- func (s ChromaSampling) ElementSamples() int
- func (s ChromaSampling) PlaneCbSamples(width, height int) int
- func (s ChromaSampling) PlaneCrSamples(width, height int) int
- func (s ChromaSampling) PlaneLumaSamples(width, height int) int
- type MatrixCoefficients
- type Primary
- type Space
- type Transfer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChromaSamplePosition ¶
type ChromaSamplePosition byte
const ( ChromaSamplePositionUnspecified ChromaSamplePosition = iota ChromaSamplePositionLeft ChromaSamplePositionCenter ChromaSamplePositionTopLeft ChromaSamplePositionTop ChromaSamplePositionBottomLeft ChromaSamplePositionBottom ChromaSamplePositionNB )
type ChromaSampling ¶
type ChromaSampling struct { // J horizontal sampling reference (width of the conceptual region). Usually, 4. J byte // A number of chrominance samples (Cb, Cr) in the first row of J pixels. A byte // B number of changes of chrominance samples (Cb, Cr) between first and second row of J pixels. Note that B has to be either zero or equal to A B byte }
ChromaSampling The subsampling scheme is commonly expressed as a three-part ratio J : A : B (e.g. 4:2:2), that describe the number of luminance and chrominance samples in a conceptual region that is J pixels wide and 2 pixels high.
func (ChromaSampling) ElementChromaSamples ¶
func (s ChromaSampling) ElementChromaSamples() int
func (ChromaSampling) ElementPixels ¶
func (s ChromaSampling) ElementPixels() int
ElementPixels returns the number of pixels for a full element
func (ChromaSampling) ElementSamples ¶
func (s ChromaSampling) ElementSamples() int
ElementSamples returns the number of actual samples (total Y, Cb, Cr) for an encoded element
func (ChromaSampling) PlaneCbSamples ¶
func (s ChromaSampling) PlaneCbSamples(width, height int) int
func (ChromaSampling) PlaneCrSamples ¶
func (s ChromaSampling) PlaneCrSamples(width, height int) int
func (ChromaSampling) PlaneLumaSamples ¶
func (s ChromaSampling) PlaneLumaSamples(width, height int) int
type MatrixCoefficients ¶
type MatrixCoefficients int
const ( MatrixBT709 MatrixCoefficients = iota MatrixBT601 MatrixBT2020NCL MatrixBT2020CL MatrixSMPTE285 )
type Space ¶
type Space struct { ChromaSampling ChromaSampling ChromaSamplePosition ChromaSamplePosition BitDepth byte }
var ( Space420 Space = newColorFormatFromStringInternal("420") Space422 Space = newColorFormatFromStringInternal("422") Space444 Space = newColorFormatFromStringInternal("444") Space420P10 Space = newColorFormatFromStringInternal("420p10") Space422P10 Space = newColorFormatFromStringInternal("422p10") Space444P10 Space = newColorFormatFromStringInternal("444p10") Space420P12 Space = newColorFormatFromStringInternal("420p12") Space422P12 Space = newColorFormatFromStringInternal("422p12") Space444P12 Space = newColorFormatFromStringInternal("444p12") Space420P16 Space = newColorFormatFromStringInternal("420p16") Space422P16 Space = newColorFormatFromStringInternal("422p16") Space444P16 Space = newColorFormatFromStringInternal("444p16") )
func (Space) MarshalJSON ¶
func (*Space) UnmarshalJSON ¶
func (*Space) UnmarshalYAML ¶
Click to show internal directories.
Click to hide internal directories.