Interface LocalFog
- All Superinterfaces:
X3DChildNode
,X3DFogObject
,X3DNode
- All Known Implementing Classes:
LocalFog
LocalFog simulates atmospheric effects by blending distant objects with fog color.
Warning: this is an abstract interface that cannot be instantiated as a concrete object. Java programmers typically only need to use concrete objects provided by the
Package hint: This interface is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI).
Warning: this is an abstract interface that cannot be instantiated as a concrete object. Java programmers typically only need to use concrete objects provided by the
org.web3d.x3d.jsail
classes.
LocalFog node tooltip: [X3DChildNode,X3DFogObject] LocalFog simulates atmospheric effects by blending distant objects with fog color. LocalFog effects occur around the local transformation center, rather than bound to the viewer. The nearest LocalFog node within range takes precedence over other LocalFog and Fog nodes.
- Hint: LocalFog effects are based on its position in the world, as given by current transformation hierarchy.
- Hint: LocalFog effects remain independent of current view location.
- Warning: LocalFog only affects geometry within the same scene subgraph.
- Warning: LocalFog is not a bindable node.
Package hint: This interface is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI).
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionfloat[]
getColor()
Provide array of 3-tuple float results using RGB values [0..1] using RGB values [0..1] from inputOutput SFColor field named color.boolean
Provide boolean value from inputOutput SFBool field named enabled.Provide String enumeration value (baseType xs:NMTOKEN) ["LINEAR" | "EXPONENTIAL"] from inputOutput SFString field named fogType.Provide org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.float
Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named visibilityRange.setColor
(float[] newValue) Accessor method to assign 3-tuple float array using RGB values [0..1] to inputOutput SFColor field named color.setEnabled
(boolean newValue) Accessor method to assign boolean value to inputOutput SFBool field named enabled.setFogType
(String newValue) Accessor method to assign String enumeration value ("LINEAR" | "EXPONENTIAL") to inputOutput SFString field named fogType.setMetadata
(X3DMetadataObject newValue) Accessor method to assign org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.setVisibilityRange
(float newValue) Accessor method to assign float value to inputOutput SFFloat field named visibilityRange.
-
Method Details
-
getColor
float[] getColor()Provide array of 3-tuple float results using RGB values [0..1] using RGB values [0..1] from inputOutput SFColor field named color.
Tooltip: [0,1] Fog color.- Hint: match Background color to make objects fade away.
- Hint: X3D Scene Authoring Hints, Color https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html#Color
- Specified by:
getColor
in interfaceX3DFogObject
- Returns:
- value of color field
-
setColor
Accessor method to assign 3-tuple float array using RGB values [0..1] to inputOutput SFColor field named color.
Tooltip: [0,1] Fog color.- Hint: match Background color to make objects fade away.
- Hint: X3D Scene Authoring Hints, Color https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html#Color
- Specified by:
setColor
in interfaceX3DFogObject
- Parameters:
newValue
- is new value for the color field.- Returns:
LocalFog
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
-
getEnabled
boolean getEnabled()Provide boolean value from inputOutput SFBool field named enabled.
Tooltip: Enables/disables node operation. *- Returns:
- value of enabled field
-
setEnabled
Accessor method to assign boolean value to inputOutput SFBool field named enabled.
Tooltip: Enables/disables node operation. *- Parameters:
newValue
- is new value for the enabled field.- Returns:
LocalFog
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
-
getFogType
String getFogType()Provide String enumeration value (baseType xs:NMTOKEN) ["LINEAR" | "EXPONENTIAL"] from inputOutput SFString field named fogType.
Tooltip: Specifies algorithm for rate of increasing Fog, either LINEAR or EXPONENTIAL.- Hint: EXPONENTIAL is more natural but also more computationally expensive.
- Warning: do not wrap extra quotation marks around these SFString enumeration values, since "quotation" "marks" are only used for MFString values.
- Specified by:
getFogType
in interfaceX3DFogObject
- Returns:
- value of fogType field
-
setFogType
Accessor method to assign String enumeration value ("LINEAR" | "EXPONENTIAL") to inputOutput SFString field named fogType.
Tooltip: Specifies algorithm for rate of increasing Fog, either LINEAR or EXPONENTIAL.- Hint: EXPONENTIAL is more natural but also more computationally expensive.
- Warning: do not wrap extra quotation marks around these SFString enumeration values, since "quotation" "marks" are only used for MFString values.
- Specified by:
setFogType
in interfaceX3DFogObject
- Parameters:
newValue
- is new value for the fogType field.- Returns:
LocalFog
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
-
getMetadata
X3DMetadataObject getMetadata()Provide org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.
Tooltip: [X3DMetadataObject] Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node.- Hint: X3D Architecture 7.2.4 Metadata https://www.web3d.org/specifications/X3Dv4/ISO-IEC19775-1v4-IS /Part01/components/core.html#Metadata
- Specified by:
getMetadata
in interfaceX3DChildNode
- Specified by:
getMetadata
in interfaceX3DNode
- Returns:
- value of metadata field
- See Also:
-
setMetadata
Accessor method to assign org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.
Tooltip: [X3DMetadataObject] Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node.- Hint: X3D Architecture 7.2.4 Metadata https://www.web3d.org/specifications/X3Dv4/ISO-IEC19775-1v4-IS /Part01/components/core.html#Metadata
- Specified by:
setMetadata
in interfaceX3DChildNode
- Specified by:
setMetadata
in interfaceX3DNode
- Parameters:
newValue
- is new value for the metadata field.- Returns:
LocalFog
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).- See Also:
-
getVisibilityRange
float getVisibilityRange()Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named visibilityRange.
Tooltip: Distance in meters where objects are totally obscured by the fog, using local coordinate system.- Hint: visibilityRange 0 disables Fog.
- Specified by:
getVisibilityRange
in interfaceX3DFogObject
- Returns:
- value of visibilityRange field
-
setVisibilityRange
Accessor method to assign float value to inputOutput SFFloat field named visibilityRange.
Tooltip: Distance in meters where objects are totally obscured by the fog, using local coordinate system.- Hint: visibilityRange 0 disables Fog.
- Specified by:
setVisibilityRange
in interfaceX3DFogObject
- Parameters:
newValue
- is new value for the visibilityRange field.- Returns:
LocalFog
- namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
-