| 651 | } |
| 652 | |
| 653 | inline float ComputeLuminance(Float3 color) |
| 654 | { |
| 655 | return Float3::Dot(color, Float3(0.299f, 0.587f, 0.114f)); |
| 656 | } |
| 657 | |
| 658 | // Convert from spherical coordinates to Cartesian coordinates(x, y, z) |
| 659 | // Theta represents how far away from the zenith (north pole/+Y) and phi represents how far |