Skip to content

raisin::IrradianceVolume ​

struct · #include <rayrai/SceneEffects.hpp>

Oriented box that adds a constant diffuse irradiance to PBR surfaces inside it.

Used as a cheap local fill/bounce light: surfaces inside the box receive color*strength* albedo * ao / pi of extra diffuse lighting. Values are sanitized by RayraiWindow::addIrradianceVolume() (ranges noted per field).

Public attributes ​

center ​

cpp
glm::vec3 center

World-space box center, metres.

halfExtents ​

cpp
glm::vec3 halfExtents

Box half-size per local axis, metres (abs, >= 0.001).

orientation ​

cpp
glm::mat3 orientation

Box rotation (columns = local axes); re-orthonormalized on add.

color ​

cpp
glm::vec3 color

Linear RGB irradiance color, [0, 8].

strength ​

cpp
float strength

Irradiance multiplier, [0, 8].

edgeFade ​

cpp
float edgeFade

Fade-in distance from the box faces in normalized local units, [0.001, 1].

normalBias ​

cpp
float normalBias

0 = uniform; 1 = weight by how much the surface normal faces world +Z, [0, 1].

RaiSim — physics for robotics and AI.