User Tools

Site Tools


02_user_tutorials:20_light:01_first_steps:10_sensor

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
02_user_tutorials:20_light:01_first_steps:10_sensor [2025/12/10 17:37] – ↷ Page moved from 02_user_tutorials:20_light:10_sensor to 02_user_tutorials:20_light:01_first_steps:10_sensor gaetan02_user_tutorials:20_light:01_first_steps:10_sensor [2026/03/25 08:46] (current) MH
Line 1: Line 1:
-===== Sensors =====+====== Sensors ======
  
 Sensors or sensor nodes are invisible objects that can be used to monitor light distributions with a scene without interfering with the rest of the scene or the light modelling. For this, GroIMP provides the //SensorNode// class, a spherical object that can be placed arbitrarily within the scene. To obtain the sensed spectrum, the function //getSensedIrradiance()// for the Twilight and the //getSensedIrradianceMeasurement()// function for the GPUFlux light model needs to be called. Sensors or sensor nodes are invisible objects that can be used to monitor light distributions with a scene without interfering with the rest of the scene or the light modelling. For this, GroIMP provides the //SensorNode// class, a spherical object that can be placed arbitrarily within the scene. To obtain the sensed spectrum, the function //getSensedIrradiance()// for the Twilight and the //getSensedIrradianceMeasurement()// function for the GPUFlux light model needs to be called.
  
-Note: The size of the sensor node directly correlates with the probability of got hit by a light ray. For a very small sphere the probability to got hit by a light ray is relatively low, so the number of light rays simulated by the light model needs to be much larger to get repayable results. Therefore, better not to use very small sensor nodes.+===== =====
  
-Note: The colour of the sensor node determines which wavelengths should be monitoredThe default value is white, what stands for 'monitor all colours'. If, for instance, the sensor colour is set to red, only red spectra will be sensed. One can even use smaller values than one, e.g., to sense less parts of a colour - if for whatever reasons this is wanted.+The size of the sensor node directly correlates with the probability of got hit by a light rayFor a very small sphere the probability to got hit by a light ray is relatively lowso the number of light rays simulated by the light model needs to be much larger to get repayable resultsThereforebetter not to use very small sensor nodes.
  
-Note: The output of a sensor node is normalized to absorbed radiance per square meter, independent of the actual size of the sensor. +The colour of the sensor node determines which wavelengths should be monitored. The default value is white, what stands for 'monitor all colours'. If, for instance, the sensor colour is set to red, only red spectra will be sensed. One can even use smaller values than one, e.g., to sense less parts of a colour - if for whatever reasons this is wanted. 
 + 
 +The output of a sensor node is normalized to absorbed radiance per square meter, independent of the actual size of the sensor.  
 + 
 +SensorNodes implement a 'Lambertian cosine factor', that models directional sensitivity — how strongly the sensor responds to radiation coming from different angles. A real flat photodetector or leaf surface responds maximally to light hitting it perpendicularly, and less to light arriving at a glancing angle. The cosine factor captures this: response ∝ cos(θ), where θ is the angle from the surface normal. 
 + 
 +The SensorNode were designed to simulate physically realistic sensors (like a leaf or a PAR sensor), not just "count all intercepted photons". Lambert's cosine law is the standard model for how a flat diffuse surface interacts with radiation. 
 + 
 +The //exponent// field generalizes the response from flat Lambertian to a cosine lobe: 
 + 
 +  * f ∝ cos(θ)^exponent 
 +  * exponent = 0 → flat/uniform response (same sensitivity from all directions above horizon) 
 +  * exponent = 1 → standard Lambertian (cos θ) 
 +  * exponent > 1 → increasingly focused on the normal direction (like a directional PAR sensor) 
 + 
 +As consequence, the results of a SensorNode with the absorption of a primitive cannot be compared directly!
  
 Note: Sensor nodes can be enabled and disabled for the light model using the //LM.setEnableSensors(true/false)// function. By default they are disabled, since GroIMP version 2.1.4, before they were enabled by default. Having them disabled speeds up the light computation time for scenarios where not sensor nodes are involved.  Note: Sensor nodes can be enabled and disabled for the light model using the //LM.setEnableSensors(true/false)// function. By default they are disabled, since GroIMP version 2.1.4, before they were enabled by default. Having them disabled speeds up the light computation time for scenarios where not sensor nodes are involved. 
02_user_tutorials/20_light/01_first_steps/10_sensor.1765384678.txt.gz · Last modified: 2025/12/10 17:37 by gaetan