MXVK Vulkan Framework 0.35.0
C++20 Vulkan rendering framework for practical 2D and 3D application development with SDL3.
Loading...
Searching...
No Matches
EncodeOptions::HdrInfo Struct Reference

HDR output options. More...

#include <MXWrite/mxwrite.hpp>

Public Attributes

int color_primaries = 0
 AVColorPrimaries value.
int color_range = 0
 AVColorRange value. Raw AVMasteringDisplayMetadata side-data bytes, or empty.
int color_space = 0
 AVColorSpace value.
int color_trc = 0
 AVColorTransferCharacteristic value.
std::vector< uint8_t > content_light
 Raw AVContentLightMetadata side-data bytes, or empty.
bool enabled = false
 Enables the HDR output path.
std::vector< uint8_t > mastering_display

Detailed Description

HDR output options.

When HdrInfo::enabled is true, the writer switches to a dedicated HEVC Main10 + BT.2020 output path that:

  • Encodes with libx265 at 10-bit (AV_PIX_FMT_YUV420P10LE).
  • Tags the stream with BT.2020 primaries, BT.2020 non-constant luminance matrix, and SMPTE ST.2084 (PQ) transfer.
  • Accepts already-PQ/HLG-encoded BT.2020 RGBA16 through the dedicated HDR write methods and converts it directly to 10-bit YUV.
  • Retains an RGBA8 compatibility path that places SDR-range content at the 100-nit reference level inside a PQ signal.
  • Copies mastering_display and content_light side data from the input stream when provided, so player HDR metadata is preserved.

This mode is intended for HDR render pipelines and preserves their 16-bit encoded signal through the RGB-to-YUV conversion.

Definition at line 122 of file mxwrite.hpp.

Member Data Documentation

◆ color_primaries

int EncodeOptions::HdrInfo::color_primaries = 0

AVColorPrimaries value.

Definition at line 124 of file mxwrite.hpp.

◆ color_range

int EncodeOptions::HdrInfo::color_range = 0

AVColorRange value. Raw AVMasteringDisplayMetadata side-data bytes, or empty.

Definition at line 127 of file mxwrite.hpp.

◆ color_space

int EncodeOptions::HdrInfo::color_space = 0

AVColorSpace value.

Definition at line 126 of file mxwrite.hpp.

◆ color_trc

int EncodeOptions::HdrInfo::color_trc = 0

AVColorTransferCharacteristic value.

Definition at line 125 of file mxwrite.hpp.

◆ content_light

std::vector<uint8_t> EncodeOptions::HdrInfo::content_light

Raw AVContentLightMetadata side-data bytes, or empty.

Definition at line 131 of file mxwrite.hpp.

◆ enabled

bool EncodeOptions::HdrInfo::enabled = false

Enables the HDR output path.

Definition at line 123 of file mxwrite.hpp.

◆ mastering_display

std::vector<uint8_t> EncodeOptions::HdrInfo::mastering_display

Definition at line 129 of file mxwrite.hpp.


The documentation for this struct was generated from the following file: