Package org.sunflow.core
Interface GIEngine
-
- All Known Implementing Classes:
AmbientOcclusionGIEngine,FakeGIEngine,InstantGI,IrradianceCacheGIEngine,PathTracingGIEngine
public interface GIEngineThis represents a global illumination algorithm. It provides an interface to compute indirect diffuse bounces of light and make those results available to shaders.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ColorgetGlobalRadiance(ShadingState state)This is an optional method for engines that contain a secondary illumination engine which can return an approximation of the global radiance in the scene (like a photon map).ColorgetIrradiance(ShadingState state, Color diffuseReflectance)Return the incomming irradiance due to indirect diffuse illumination at the specified surface point.booleaninit(Options options, Scene scene)Initialize the engine.
-
-
-
Method Detail
-
getGlobalRadiance
Color getGlobalRadiance(ShadingState state)
This is an optional method for engines that contain a secondary illumination engine which can return an approximation of the global radiance in the scene (like a photon map). Engines can safely returnColor.BLACKif they can't or don't wish to support this.- Parameters:
state- shading state- Returns:
- color approximating global radiance
-
init
boolean init(Options options, Scene scene)
Initialize the engine. This is called before rendering begins.- Returns:
trueif the init phase succeeded,falseotherwise
-
getIrradiance
Color getIrradiance(ShadingState state, Color diffuseReflectance)
Return the incomming irradiance due to indirect diffuse illumination at the specified surface point.- Parameters:
state- current render state describing the point to be computeddiffuseReflectance- diffuse albedo of the point being shaded, this can be used for importance tracking- Returns:
- irradiance from indirect diffuse illumination at the specified point
-
-