java.lang.Object
de.grogra.persistence.ShareableBase
de.grogra.rgg.LightModelBase
- All Implemented Interfaces:
Manageable
,Shareable
- Direct Known Subclasses:
FluxLightModel
,LightModel
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract void
compute()
(Re-)computes the light distribution in the current graph.abstract void
compute
(boolean force) (Re-)computes the light distribution in the current graph.abstract void
(Re-)computes the light distribution in the current graph.abstract void
(Re-)computes the light distribution in the current graph.abstract Spectrum
getAbsorbedPower
(Node node) Returns the radiant power in Watts which is absorbed by the surface of the volume of the givennode
.getAbsorbedPower3d
(Node node) Returns the radiant power in Watts which is absorbed by the surface of the volume of the givennode
, represented as aSpectrum3d
.getRadiantPower3dFor
(Node node) Deprecated.getRadiantPowerFor
(Node node) Deprecated.abstract Spectrum
getSensedIrradiance
(Node node) Returns the irradiance in Watts per square meter which is sensed by the sensor attached to the volume of the givennode
.getSensedIrradiance3d
(Node node) abstract void
setLayerVisible
(int layer, boolean visible) sets the visibility of a layerMethods inherited from class de.grogra.persistence.ShareableBase
addReference, appendReferencesTo, fieldModified, getProvider, getStamp, initProvider, manageableReadResolve, manageableWriteReplace, removeReference
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface de.grogra.persistence.Manageable
getManageableType
-
Field Details
-
$TYPE
-
-
Constructor Details
-
LightModelBase
public LightModelBase()
-
-
Method Details
-
compute
public abstract void compute()(Re-)computes the light distribution in the current graph. -
compute
(Re-)computes the light distribution in the current graph.- Parameters:
spectrumFactory
- factrory for spectrum objects
-
compute
public abstract void compute(boolean force) (Re-)computes the light distribution in the current graph.- Parameters:
force
- if true forces recomputation of the light distribution
-
compute
(Re-)computes the light distribution in the current graph. This method has to be invoked at first in order forgetRadiantPowerFor(de.grogra.graph.impl.Node)
,getAbsorbedPower(de.grogra.graph.impl.Node)
andgetSensedIrradiance(de.grogra.graph.impl.Node)
to return correct values.- Parameters:
spectrumFactory
- factrory for spectrum objectsforce
- if true forces recomputation of the light distribution
-
getRadiantPowerFor
Deprecated.Deprecated, use getAbsorbedPower(node) instead.- Parameters:
node
-- Returns:
-
getRadiantPower3dFor
Deprecated.Deprecated, use getAbsorbedPower3d(node) instead.- Parameters:
node
-- Returns:
-
getAbsorbedPower
Returns the radiant power in Watts which is absorbed by the surface of the volume of the givennode
. If thenode
does not define a volume, the zero spectrum is returned.- Parameters:
node
- a node of the graph- Returns:
- the absorbed radiant power of the node
-
getAbsorbedPower3d
Returns the radiant power in Watts which is absorbed by the surface of the volume of the givennode
, represented as aSpectrum3d
. If thenode
does not define a volume, the zero spectrum is returned.- Parameters:
node
- a node of the graph- Returns:
- the absorbed radiant power of the node
-
getSensedIrradiance
Returns the irradiance in Watts per square meter which is sensed by the sensor attached to the volume of the givennode
. If thenode
does not define a volume with a sensor, the zero spectrum is returned.- Parameters:
node
- a node of the graph- Returns:
- the sensed irradiance of the node
-
getSensedIrradiance3d
-
setLayerVisible
public abstract void setLayerVisible(int layer, boolean visible) sets the visibility of a layer
-