Microsoft DirectX 9.0 SDK Update (October 2004)

PrtEngine.ComputeDirectLightingSphericalHarmonicsAdaptive Method

Language:

Note: This documentation is preliminary and is subject to change.

Computes the direct-lighting contribution to 3-D objects where the source radiance is represented by a spherical harmonic (SH) approximation, using adaptive sampling. This method generates new vertices and faces on the mesh to more accurately approximate the precomputed radiance transfer (PRT) signal.

Definition

Visual Basic .NET Public Sub ComputeDirectLightingSphericalHarmonicsAdaptive( _
    ByVal shOrder As Integer, _
    ByVal adaptiveThreshold As Single, _
    ByVal minEdgeLength As Single, _
    ByVal maxSubDiv As Integer, _
    ByVal data As PrtBuffer _
)
C# public void ComputeDirectLightingSphericalHarmonicsAdaptive(
    int shOrder,
    float adaptiveThreshold,
    float minEdgeLength,
    int maxSubDiv,
    PrtBuffer data
);
Managed C++ public: void ComputeDirectLightingSphericalHarmonicsAdaptive(
    int shOrder,
    float adaptiveThreshold,
    float minEdgeLength,
    int maxSubDiv,
    PrtBuffer *data
);
JScript .NET public function ComputeDirectLightingSphericalHarmonicsAdaptive(
    shOrder : int,
    adaptiveThreshold : float,
    minEdgeLength : float,
    maxSubDiv : int,
    data : PrtBuffer
);

Parameters

shOrder System.Int32. Order of the spherical harmonic (SH) evaluation. Must be in the range of SphericalHarmonics.MinimumOrder to SphericalHarmonics.MaximumOrder, inclusive. The evaluation generates shOrder2 coefficients. The degree of the evaluation is shOrder - 1.
adaptiveThreshold System.Single. Threshold on the precomputed radiance transfer (PRT) vector to use for subdividing mesh vertices and faces. If less than 1e-6f, a default value of 1e-6f is specified.
minEdgeLength System.Single. Minimum face edge length that will be generated in adaptive sampling. If the method determines that the value is too small, a model-dependent value is specified. If zero, a default value of 4 is specified.
maxSubDiv System.Int32. Maximum level of subdivision of a face that will be used in adaptive sampling.
data Microsoft.DirectX.Direct3D.PrtBuffer. A PrtBuffer object that contains the output data. This buffer must have the proper number of color channels allocated for the simulation.

Remarks

Exceptions
InvalidCallException The method call is invalid. For example, a method's parameter might contain an invalid value.
OutOfMemoryException Leave Site Microsoft® Direct3D® could not allocate sufficient memory to complete the call.

See Also


© 2004 Microsoft Corporation. All rights reserved. Terms of use.

Feedback? Please provide us with your comments on this topic.
For more help, visit the DirectX Developer Center