XML Reference

 

Base class: BSDF
Type: Dynamically instantiatable
Description: The Lambertian shader makes a surface perfectly and uniformly reflective with an equal radiance distribution in all directions.
Syntax:  
   
  <bsdf class="lambertian" name="[shader name]">
       
     
  <hemisphere samples="[1..inf]"/>
       
     

The hemisphere attribute determines the resolution of the spread of samples taken to calculate the irradiance at each point on the surface.

Increase the hemisphere resolution to reduce the noise in the final image. This is based upon the law of deminishing returns which means that the pixel standard deviation is proportinal to one over the number of samples taken. In other words, the difference between 1000 and 2000 samples per pixel will be far less pronounced than the difference between 50 and 100 samples per pixel. A value of 200 to 500 is recommended for good-quality renders.

     
       
     
 

<illumination
   globaldiffuse="[boolean]"
   localdiffuse="[boolean]"
   primarylocal="[boolean]"
   constellation="[boolean]"
   finalgather="[boolean]"
   emission="[boolean]"
   irradiancecache="[boolean]"
   debugphotons="[boolean]"
/>

       
     

The illumination attribute allows certain components of incoming illumination to be selectively enabled and disabled

globaldiffuse Enables/disables the factoring in of global diffuse illumination
localdiffuse Enables/disables the factoring in of local diffuse illumination from explicit luminaries
primarylocal Enables/disables the factoring in of local illumination on primary rays
constellation Enables/disables the factoring in of light from a constellation generated by a skylight
finalgather Enables/disables final gather from the photon map. A diffuse photon map object must also be specified for this flag to have any effect (see photon mapping for more information)
emission Enables/disables the factoring in of light from emissive surfaces.
irradiancecache Enables/disables irradiance caching. An irradiance cache object must also be specified for this flag to have any effect (see irradiance caching for more information)
debugphotons Enables/disables direct photon map visualisation. In other words, specular rays are treated like final gather rays allowing the photon map to become visible.
     
       
     
 

<russianroulette
   threshold="[min..1.0f]"
/>

       
     

The russian roulette parameter determines the cutoff parameters when spawning diffuse rays.

threshold  
     
  </bsdf>