eradiate.scenes.bsdfs.HapkeBSDF#

class eradiate.scenes.bsdfs.HapkeBSDF(id=None, w=None, b=None, c=None, theta=0.183, B_0=None, h=None)[source]#

Bases: BSDF

Hapke BSDF [hapke].

This BSDF implements the Hapke surface model as described in []. This highly flexible and robust surface model allows for the characterisation of a sharp back-scattering hot spot. The so-called Hapke model has been adapted to several different use cases in the litterature, the version with 6 parameters implemented here is one of the most commonly used.

Parameters:
  • id (str, optional) – Identifier of the current scene element.

  • w (Spectrum or dict or float) – Single scattering albedo ‘w’. Must be in [0; 1]

  • b (Spectrum or dict or float) – Anisotropy parameter ‘b’ Must be in [0; 1]

  • c (Spectrum or dict or float) – Scattering coefficient ‘c’. Must be in [0; 1]

  • theta (quantity or float) – Photometric roughness ‘theta’. Angle in degree. Must be in [0; 90]°

  • B_0 (Spectrum or dict or float) – Shadow hiding opposition effect amplitude ‘B_0’. Must be in [0; 1]

  • h (Spectrum or dict or float) – shadow hiding opposition effect width ‘h’. Must be in [0; 1]

Fields:
  • id (str or None) – Identifier of the current scene element.

  • w (Spectrum) – Single scattering albedo ‘w’.

  • b (Spectrum) – Anisotropy parameter ‘b’ Must be in [0; 1].

  • c (Spectrum) – Scattering coefficient ‘c’.

  • theta (Spectrum) – Photometric roughness ‘theta’.

  • B_0 (Spectrum) – Shadow hiding opposition effect amplitude ‘B_0’.

  • h (Spectrum) – shadow hiding opposition effect width ‘h’.

traverse(callback)#

Traverse this scene element and collect kernel dictionary template and parameter update map contributions.

Parameters:

callback (SceneTraversal) – Callback data structure storing the collected data.

update()#

Enforce internal state consistency. This method should be called when fields are modified. It is automatically called as a post-init step.

property objects#

Map of child objects associated with this scene element.

Returns:

dict – A dictionary mapping object names to a corresponding object to be inserted in the Eradiate scene graph.

property params#
Returns:

dict[str, UpdateParameter] or None – A dictionary mapping parameter paths, consisting of dot-separated strings, to a corresponding update protocol.

property template#

Kernel dictionary template contents associated with this scene element.

Returns:

dict – A flat dictionary mapping dot-separated strings describing the path of an item in the nested scene dictionary to values. Values may be objects which can be directly used by the mitsuba.load_dict() function, or InitParameter instances which must be rendered.