Computes locally-deformable precomputed radiance transfer (LDPRT) coefficients relative to per-sample normal vectors to minimize the least-squares error with respect to input ID3DXPRTBuffer data. These coefficients can be used with skinned or transformed normal vectors to model global effects on dynamic objects.
HRESULT ComputeLDPRTCoeffs( LPD3DXPRTBUFFER pDataIn, UINT Order, D3DXVECTOR3 * pNormOut, LPD3DXPRTBUFFER pDataOut );
If the method succeeds, the return value is D3D_OK. If the method fails, the return value can be one of the following: D3DERR_INVALIDCALL, E_OUTOFMEMORY.
Solutions for shading normal vectors can optionally be obtained with this method. These normal vectors, along with the LDPRT coefficients, can more accurately represent the PRT signal. In this case, the coefficients represent zonal harmonics oriented in the normal direction.
This method cannot be used with results from ID3DXPRTEngine::ComputeSurfSamplesBounce or ID3DXPRTEngine::ComputeSurfSamplesDirectSH.
Header: Declared in D3dx9mesh.h.