载入中...
搜索中...
未找到
eve::graphics::display 命名空间参考

类

struct  Support
 Support public API. 更多...
 

枚举

enum class  ActiveColorSpace : uint8_t { Sdr = 0 , ScRgb = 1 , Hdr10 = 2 }
 Active present color encoding after swapchain selection. 更多...
 
enum class  OutputMode : uint8_t { Sdr = 0 , Auto = 1 , Hdr10 = 2 , ScRgb = 3 }
 Requested present preference; Auto picks Hdr10 then ScRgb then Sdr. 更多...
 

函数

void clampCalibration (float &paperWhiteNits, float &peakNits) noexcept
 Clamp paper-white / peak luminance into the engine-supported range.
 
float packNits (float paperWhiteNits, float peakNits) noexcept
 Pack paper-white and peak nits into one float for the present resolve tint.
 
void unpackNits (float packed, float &paperWhiteNits, float &peakNits) noexcept
 Unpack paper-white and peak nits from the present resolve tint channel.
 
float packActiveMode (ActiveColorSpace space) noexcept
 Encode the active present mode into the resolve tint G channel.
 
float packComposeLinearMode () noexcept
 Tint G value for compose-linear output (paper-white-relative, no OETF).
 
ActiveColorSpace unpackActiveMode (float packed) noexcept
 Decode the present mode from the resolve tint G channel.
 
bool isComposeLinearMode (float packed) noexcept
 True when the tint G channel requests compose-linear (mode 3).
 
Color sceneResolveTint (bool aces, ActiveColorSpace space, bool attachmentEncodesSrgb, float paperWhiteNits, float peakNits) noexcept
 Build the Color tint used by the final scene present resolve.
 
Color sceneComposeTint (bool aces, float paperWhiteNits, float peakNits) noexcept
 Build the Color tint for tonemapping into a linear HDR compose target.
 
Color uiResolveTint (ActiveColorSpace space, float paperWhiteNits, float peakNits) noexcept
 Build the Color tint used when compositing SDR UI onto an HDR swapchain.
 
float luminanceRec709 (float r, float g, float b) noexcept
 Luminance rec 709.
 
void rec709ToRec2020 (float &r, float &g, float &b) noexcept
 Convert display-linear Rec.709 RGB into Rec.2020.
 
float linearToPq (float v) noexcept
 Apply the ST.2084 PQ OETF to a [0,1] normalized luminance sample.
 
void encodeHdr10 (float &r, float &g, float &b, float paperWhiteNits, float peakNits) noexcept
 Map filmic display-linear RGB (1 = paper white) into HDR10 PQ codes.
 
void acesToDisplayLinear (float &r, float &g, float &b, float paperWhiteNits, float peakNits) noexcept
 Expand ACES [0,1] output into display-linear relative to paper white.
 
void encodeScRgb (float &r, float &g, float &b, float paperWhiteNits, float peakNits) noexcept
 Map paper-white-relative display-linear RGB into scRGB (1.0 = 80 nits).
 

变量

constexpr float kDefaultPaperWhiteNits = 200.f
 
constexpr float kDefaultPeakNits = 1000.f
 

枚举类型说明

◆ ActiveColorSpace

enum class eve::graphics::display::ActiveColorSpace : uint8_t
strong

Active present color encoding after swapchain selection.

枚举值
Sdr 
ScRgb 
Hdr10 

在文件 DisplayOutputEncoding.h 第 12 行定义.

◆ OutputMode

enum class eve::graphics::display::OutputMode : uint8_t
strong

Requested present preference; Auto picks Hdr10 then ScRgb then Sdr.

枚举值
Sdr 
Auto 
Hdr10 
ScRgb 

在文件 DisplayOutputEncoding.h 第 15 行定义.

函数说明

◆ acesToDisplayLinear()

void eve::graphics::display::acesToDisplayLinear ( float &  r,
float &  g,
float &  b,
float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Expand ACES [0,1] output into display-linear relative to paper white.

Tonemap in a scaled domain so the shoulder lands near peak/paperWhite.

Clamp calibration.

Clamp.

在文件 DisplayOutputEncoding.h 第 157 行定义.

引用了 a, b, c, clampCalibration(), d, g , 以及 r.

◆ clampCalibration()

void eve::graphics::display::clampCalibration ( float &  paperWhiteNits,
float &  peakNits 
)
inlinenoexcept

Clamp paper-white / peak luminance into the engine-supported range.

在文件 DisplayOutputEncoding.h 第 28 行定义.

被这些函数引用 acesToDisplayLinear(), encodeHdr10(), encodeScRgb(), packNits(), eve::graphics::Graphics::setDisplayHdrCalibration(), eve::graphics::vulkan::Graphics::setDisplayHdrCalibration() , 以及 unpackNits().

◆ encodeHdr10()

void eve::graphics::display::encodeHdr10 ( float &  r,
float &  g,
float &  b,
float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Map filmic display-linear RGB (1 = paper white) into HDR10 PQ codes.

参数
r,g,bDisplay-linear Rec.709 channels relative to paper white.

Clamp calibration.

Rec 709 to rec 2020.

在文件 DisplayOutputEncoding.h 第 138 行定义.

引用了 b, clampCalibration(), g, linearToPq(), r , 以及 rec709ToRec2020().

◆ encodeScRgb()

void eve::graphics::display::encodeScRgb ( float &  r,
float &  g,
float &  b,
float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Map paper-white-relative display-linear RGB into scRGB (1.0 = 80 nits).

参数
r,g,bDisplay-linear Rec.709 channels relative to paper white.

Clamp calibration.

在文件 DisplayOutputEncoding.h 第 178 行定义.

引用了 b, clampCalibration(), g, r , 以及 scale.

◆ isComposeLinearMode()

bool eve::graphics::display::isComposeLinearMode ( float  packed)
inlinenoexcept

True when the tint G channel requests compose-linear (mode 3).

Int.

在文件 DisplayOutputEncoding.h 第 77 行定义.

◆ linearToPq()

float eve::graphics::display::linearToPq ( float  v)
inlinenoexcept

Apply the ST.2084 PQ OETF to a [0,1] normalized luminance sample.

Pow.

在文件 DisplayOutputEncoding.h 第 122 行定义.

引用了 v.

被这些函数引用 encodeHdr10().

◆ luminanceRec709()

float eve::graphics::display::luminanceRec709 ( float  r,
float  g,
float  b 
)
inlinenoexcept

Luminance rec 709.

在文件 DisplayOutputEncoding.h 第 107 行定义.

引用了 b, g , 以及 r.

◆ packActiveMode()

float eve::graphics::display::packActiveMode ( ActiveColorSpace  space)
inlinenoexcept

Encode the active present mode into the resolve tint G channel.

Shader modes: 0=SDR, 1=scRGB, 2=HDR10, 3=compose-linear (no encode).

在文件 DisplayOutputEncoding.h 第 53 行定义.

引用了 Hdr10, ScRgb , 以及 Sdr.

被这些函数引用 sceneResolveTint() , 以及 uiResolveTint().

◆ packComposeLinearMode()

float eve::graphics::display::packComposeLinearMode ( )
inlinenoexcept

Tint G value for compose-linear output (paper-white-relative, no OETF).

在文件 DisplayOutputEncoding.h 第 66 行定义.

被这些函数引用 sceneComposeTint().

◆ packNits()

float eve::graphics::display::packNits ( float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Pack paper-white and peak nits into one float for the present resolve tint.

Clamp calibration.

在文件 DisplayOutputEncoding.h 第 34 行定义.

引用了 clampCalibration().

被这些函数引用 sceneComposeTint(), sceneResolveTint() , 以及 uiResolveTint().

◆ rec709ToRec2020()

void eve::graphics::display::rec709ToRec2020 ( float &  r,
float &  g,
float &  b 
)
inlinenoexcept

Convert display-linear Rec.709 RGB into Rec.2020.

在文件 DisplayOutputEncoding.h 第 112 行定义.

引用了 b, g , 以及 r.

被这些函数引用 encodeHdr10().

◆ sceneComposeTint()

Color eve::graphics::display::sceneComposeTint ( bool  aces,
float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Build the Color tint for tonemapping into a linear HDR compose target.

Mode 3 skips PQ/scRGB encode so overlays can blend in display-linear space.

Color.

在文件 DisplayOutputEncoding.h 第 94 行定义.

引用了 packComposeLinearMode() , 以及 packNits().

◆ sceneResolveTint()

Color eve::graphics::display::sceneResolveTint ( bool  aces,
ActiveColorSpace  space,
bool  attachmentEncodesSrgb,
float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Build the Color tint used by the final scene present resolve.

Color.

在文件 DisplayOutputEncoding.h 第 83 行定义.

引用了 packActiveMode(), packNits() , 以及 Sdr.

◆ uiResolveTint()

Color eve::graphics::display::uiResolveTint ( ActiveColorSpace  space,
float  paperWhiteNits,
float  peakNits 
)
inlinenoexcept

Build the Color tint used when compositing SDR UI onto an HDR swapchain.

Color.

在文件 DisplayOutputEncoding.h 第 100 行定义.

引用了 packActiveMode() , 以及 packNits().

◆ unpackActiveMode()

ActiveColorSpace eve::graphics::display::unpackActiveMode ( float  packed)
inlinenoexcept

Decode the present mode from the resolve tint G channel.

在文件 DisplayOutputEncoding.h 第 69 行定义.

引用了 Hdr10, ScRgb , 以及 Sdr.

◆ unpackNits()

void eve::graphics::display::unpackNits ( float  packed,
float &  paperWhiteNits,
float &  peakNits 
)
inlinenoexcept

Unpack paper-white and peak nits from the present resolve tint channel.

Clamp calibration.

在文件 DisplayOutputEncoding.h 第 43 行定义.

引用了 clampCalibration().

变量说明

◆ kDefaultPaperWhiteNits

constexpr float eve::graphics::display::kDefaultPaperWhiteNits = 200.f
inlineconstexpr

在文件 DisplayOutputEncoding.h 第 24 行定义.

◆ kDefaultPeakNits

constexpr float eve::graphics::display::kDefaultPeakNits = 1000.f
inlineconstexpr

在文件 DisplayOutputEncoding.h 第 25 行定义.