Edit

Share via


D3DCompressShaders function (d3dcompiler.h)

Note  You can use this API to develop your Windows Store apps, but you can't use it in apps that you submit to the Windows Store.
 
Compresses a set of shaders into a more compact form.

Syntax

HRESULT D3DCompressShaders(
  [in]  UINT            uNumShaders,
  [in]  D3D_SHADER_DATA *pShaderData,
  [in]  UINT            uFlags,
  [out] ID3DBlob        **ppCompressedData
);

Parameters

[in] uNumShaders

Type: UINT

The number of shaders to compress.

[in] pShaderData

Type: D3D_SHADER_DATA*

An array of D3D_SHADER_DATA structures that describe the set of shaders to compress.

[in] uFlags

Type: UINT

Flags that indicate how to compress the shaders. Currently, only the D3D_COMPRESS_SHADER_KEEP_ALL_PARTS (0x00000001) flag is defined.

[out] ppCompressedData

Type: ID3DBlob**

The address of a pointer to the ID3DBlob interface that is used to retrieve the compressed shader data.

Return value

Type: HRESULT

Returns one of the Direct3D 11 return codes.

Requirements

Requirement Value
Target Platform Windows
Header d3dcompiler.h
Library D3DCompiler.lib
DLL D3DCompiler_47.dll

See also

Functions