1
0
mirror of https://github.com/microsoft/DirectXTex synced 2024-11-23 04:50:06 +00:00
4 FormatPromoters
Chuck Walbourn edited this page 2022-07-27 16:58:24 -07:00
DirectXTex

These functions are intended to 'promote' a DXGI format with some special property, if there is such a defined type.

DXGI_FORMAT MakeSRGB(DXGI_FORMAT fmt);
DXGI_FORMAT MakeLinear(DXGI_FORMAT fmt);
DXGI_FORMAT MakeTypeless(DXGI_FORMAT fmt);
DXGI_FORMAT MakeTypelessUNORM(DXGI_FORMAT fmt);
DXGI_FORMAT MakeTypelessFLOAT(DXGI_FORMAT fmt);

Parameters

These functions all take a DXGI_FORMAT as input.

Return value

The return value is the promoted type if it exists. Otherwise, the original input type is returned.

Remarks

MakeTypelessUNORM will promote a _TYPELESS format to a matching _UNORM data type if it exists. Otherwise it returns the original type.

MakeTypelessFLOAT will promote a _TYPELESS format to a matching _FLOAT data type if it exists. Otherwise it returns the original type.