Function libredr::light_source::functional_envmap

source ·
pub fn functional_envmap<F>(resolution: usize, f: F) -> Result<Array4<f32>>
where F: FnMut(Vector3<f32>) -> Vector3<f32>,
Expand description

Functional light source models (Rust) Construct envmap with a given function

§Arguments

  • resolution: a single integer
  • f: function converting the normalized envmap direction (f32 vector of 3) to intensity (f32 vector of 3)

§Return

  • 3 * 6 * resolution * resolution