D3DX10CreateEffectPoolFromResource function

Create an effect pool from a resource.

Syntax

HRESULT D3DX10CreateEffectPoolFromResource(
  _In_        HMODULE            hModule,
  _In_        LPCTSTR            pResourceName,
  _In_        LPCTSTR            pSrcFileName,
  _In_  const D3D_SHADER_MACRO *pDefines,
  _In_        ID3D10Include      *pInclude,
  _In_        LPCSTR             pProfile,
  _In_        UINT               HLSLFlags,
  _In_        UINT               FXFlags,
  _In_        ID3D10Device       *pDevice,
  _In_        ID3DX10ThreadPump  *pPump,
  _In_        ID3D10EffectPool   **ppEffectPool,
  _In_        ID3D10Blob         **ppErrors,
  _Out_       HRESULT            *pHResult
);

Parameters

hModule [in]

Type: HMODULE

A handle to the resource module containing the effect. HMODULE can be obtained with GetModuleHandle Function.

pResourceName [in]

Type: LPCTSTR

The name of the resource in hModule. If the compiler settings require Unicode, the data type LPCTSTR resolves to LPCWSTR. Otherwise, the data type resolves to LPCSTR.

pSrcFileName [in]

Type: LPCTSTR

Optional. Effect file name, which is used for error messages only. Can be NULL.

pDefines [in]

Type: const D3D_SHADER_MACRO*

A NULL-terminated array of shader macros (see D3D_SHADER_MACRO); set this to NULL to specify no macros.

pInclude [in]

Type: ID3D10Include*

A pointer to an include interface (see ID3D10Include Interface). This parameter can be NULL.

pProfile [in]

Type: LPCSTR

A string that specifies the shader profile, or shader model.

HLSLFlags [in]

Type: UINT

HLSL compile options (see D3D10_SHADER Constants).

FXFlags [in]

Type: UINT

Effect compile options (see Compile and Effect Flags).

pDevice [in]

Type: ID3D10Device*

A pointer to the device (see ID3D10Device Interface) that will use the resources.

pPump [in]

Type: ID3DX10ThreadPump*

A pointer to a thread pump interface (see ID3DX10ThreadPump Interface). Use NULL to specify that this function should not return until it is completed.

ppEffectPool [in]

Type: ID3D10EffectPool**

The address of a pointer to the effect pool (see ID3D10EffectPool Interface).

ppErrors [in]

Type: ID3D10Blob**

The address of a pointer to memory (see ID3D10Blob Interface) that contains effect compile errors, if there were any.

pHResult [out]

Type: HRESULT*

A pointer to the return value. May be NULL. If pPump is not NULL, then pHResult must be a valid memory location until the asynchronous execution completes.

Return value

Type: HRESULT

The return value is one of the values listed in Direct3D 10 Return Codes.

Requirements

Requirement Value
Header
D3DX10Async.h

See also

General Purpose Functions