XGDecodeDCC

Decodes (decompresses) a delta color compressed surface.

Syntax

HRESULT XGDecodeDCC(
         UINT32 DataSizeBlocks,
         const void *pSourceData,
         const void *pSourceKeys,
         void *pDestData,
         XG_FORMAT Format,
         XG_TILE_MODE TileMode,
         const XG_DCC_OPTIONS *pDccOptions
)  

Parameters

DataSizeBlocks
Type: UINT32 

[in] The number of 256-byte blocks of compressed color data in pSourceData.

pSourceData
Type: void *

[in] The address of a buffer containing delta-color-compressed color values. The size of the buffer is 256 bytes multiplied by DataSizeBlocks.

pSourceKeys
Type: void *

[in] The address of a buffer containing DCC key values, one byte per compressed block. The size of the buffer is DataSizeBlocks.

pDestData
Type: void *

[out] The address of the buffer where decoded (decompressed) color data will be stored. The size of the buffer should be the same as the size of the buffer specified in pSourceData, 256 bytes multiplied by DataSizeBlocks.

Format
Type: XG_FORMAT 

[in] The color format of the decompressed color data.

TileMode
Type: XG_TILE_MODE 

[in] The tile mode of the decompressed color data.

pDccOptions
Type: XG_DCC_OPTIONS *

[in] Specifies the DCC encoding options of the decompressed color data.

Return value

Type: HRESULT 

One of the return codes described in Direct3D 11 return codes.

Remarks

XGDecodeDCC is an implementation of a software DCC decoder suitable for use in tools or off-line decompression. Its not a high-performance implementation suitable or intended for use during runtime.

See also

XGEncodeDCC

Requirements

Header: Declared in xg.h.

Library: Use xg_x.lib.