|
|
|
|
|
|
#if SSS_USE_TANGENT_PLANE |
|
|
|
// Both 'xy2' and 'z' require conversion to millimeters. |
|
|
|
float r = sqrt(xy2 + z * z) * mmPerUnit; |
|
|
|
float p = sqrt(xy2) * mmPerUnit; |
|
|
|
float p = sqrt(xy2); |
|
|
|
#endif |
|
|
|
|
|
|
|
float area = rcpPdf; |
|
|
|
|
|
|
|
#if 0 |
|
|
|
// Boost the area associated with the sample by the ratio between the sample-center distance |
|
|
|
// and its orthogonal projection onto the integration plane (disk). |
|
|
|
area *= r / p; |
|
|
|
return saturate(DisneyProfilePolar(r, S) * rcpPdf); |
|
|
|
return saturate(DisneyProfilePolar(r, S) * area); |
|
|
|
return DisneyProfilePolar(r, S) * rcpPdf; |
|
|
|
return DisneyProfilePolar(r, S) * area; |
|
|
|
#endif |
|
|
|
} |
|
|
|
|
|
|
|