![]() |
![]() |
![]() |
Sets sampling properties used by the precomputed radiance transfer (PRT) simulator.
Syntax
HRESULT SetSamplingInfo(
UINT NumRays, BOOL UseSphere, BOOL UseCosine, BOOL Adaptive, FLOAT AdaptiveThresh );
Parameters
- NumRays
- [in] Number of light rays to direct at each sample. Must be greater than zero.
- UseSphere
- [in] If TRUE, samples will be computed over a full sphere. If FALSE, samples will be computed over a hemisphere.
- UseCosine
- [in] If TRUE, use a cosine weighting of samples. If both UseCosine and UseSphere are TRUE, the method will fail and an error will be returned.
- Adaptive
- [in] Must be FALSE. Adaptive sampling is currently not implemented.
- AdaptiveThresh
- [in] Ignored.
Return Value
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 The method call is invalid. For example, a method's parameter may have an invalid value. E_NOTIMPL Not implemented. E_OUTOFMEMORY Microsoft Direct3D could not allocate sufficient memory to complete the call.