ID3D11Linker::Link method

Links the shader and produces a shader blob that the Direct3D runtime can use.

Syntax

HRESULT Link(
  ID3D11ModuleInstance *pEntry,
  LPCSTR               pEntryName,
  LPCSTR               pTargetName,
  UINT                 uFlags,
  ID3DBlob             **ppShaderBlob,
  ID3DBlob             **ppErrorBuffer
);

Parameters

pEntry

Type: ID3D11ModuleInstance*

A pointer to the ID3D11ModuleInstance interface for the shader module instance to link from.

pEntryName

Type: LPCSTR

The name of the shader module instance to link from.

pTargetName

Type: LPCSTR

The name for the shader blob that is produced.

uFlags

Type: UINT

Reserved.

ppShaderBlob

Type: ID3DBlob**

A pointer to a variable that receives a pointer to the ID3DBlob interface that you can use to access the compiled shader code.

ppErrorBuffer

Type: ID3DBlob**

A pointer to a variable that receives a pointer to the ID3DBlob interface that you can use to access compiler error messages.

Return Value

Type: HRESULT

Returns S_OK if successful; otherwise, returns one of the Direct3D 11 Return Codes.

Requirements

   
Target Platform Windows
Header d3d11shader.h
Library D3DCompiler.lib
DLL D3DCompiler_47.dll

See Also

ID3D11Linker