public static int ThetaDiff_index( double _ThetaDiff, out double _Interpolant )
{
double fIndex = _ThetaDiff / (Math.PI * 0.5) * BRDF_SAMPLING_RES_THETA_D;
int Index = (int) Math.Floor( fIndex );
_Interpolant = fIndex - Index;
Index = Math.Max( 0, Math.Min( Index, BRDF_SAMPLING_RES_THETA_D-1 ) );
return Index;
}