ID3DXPRTEngine::SetPerTexelAlbedo method

Sets an albedo value for each texel, overwriting previous albedo values.

Syntax

HRESULT SetPerTexelAlbedo(
  [in] LPDIRECT3DTEXTURE9        pAlbedoTexture,
  [in] UINT                      NumChannels,
  [in] LPD3DXTEXTUREGUTTERHELPER pGH
);

Parameters

pAlbedoTexture [in]

Type: LPDIRECT3DTEXTURE9

Pointer to an IDirect3DTexture9 texture object in which to store albedo values.

NumChannels [in]

Type: UINT

Number of color channels to set. Set to 1 to specify gray materials (R = G = B), or 3 to enable color bleeding effects.

pGH [in]

Type: LPD3DXTEXTUREGUTTERHELPER

Optional pointer to an ID3DXTextureGutterHelper object. If not provided, a texture gutter helper object is created and destroyed internally.

Return value

Type: HRESULT

If the method succeeds, the return value is S_OK. If the method fails, the return value can be one of the following: D3DERR_INVALIDCALL, D3DERR_NOTAVAILABLED3DERR_OUTOFVIDEOMEMORY, D3DERR_WASSTILLDRAWING, E_OUTOFMEMORY.

Requirements

Requirement Value
Header
D3DX9Mesh.h
Library
D3dx9.lib

See also

ID3DXPRTEngine