JMSLTM Numerical Library 5.0.1

com.imsl.chart3d
Class ChartNode3D

java.lang.Object
  extended by com.imsl.chart.AbstractChartNode
      extended by com.imsl.chart3d.ChartNode3D
All Implemented Interfaces:
Serializable, Cloneable
Direct Known Subclasses:
AmbientLight, Axis3D, AxisBox, AxisLabel, AxisLine, AxisTitle, AxisXYZ, Background, Chart3D, ChartLights, ColormapLegend, Data, DirectionalLight, MajorTick, PointLight

public abstract class ChartNode3D
extends AbstractChartNode
implements Serializable

The base class of all of the nodes in the 3D chart tree.

See Also:
Serialized Form

Field Summary
static int AXIS_TITLE_AT_END
          Value for attribute "AxisTitlePosition" indicating that the axis title should be placed at the end of the axis.
static int AXIS_TITLE_PARALLEL
          Value for attribute "AxisTitlePosition" indicating that the axis title should be placed parallel to the axis.
static int DATA_TYPE_LINE
          Value for attribute "DataType" indicating that the data points should be connected with line segments.
static int DATA_TYPE_MARKER
          Value for attribute "DataType" indicating that a marker should be drawn at each data point.
static int DATA_TYPE_PICTURE
          Value for attribute "DataType" indicating that an image (attribute "Image") should be drawn at each data point.
static int DATA_TYPE_TUBE
          Value for attribute "DataType" indicating that a tube connecting the data points should be drawn.
static int MARKER_TYPE_CUBE
          Flag for a cube data marker.
static int MARKER_TYPE_CUSTOM
          Flag for a custom marker
static int MARKER_TYPE_PLUS
          Flag for a 3D plus sign data marker.
static int MARKER_TYPE_SIMPLE_CUBE
          Flag for a simple cube (no edge) data marker.
static int MARKER_TYPE_SIMPLE_PLUS
          Flag for a simple 2D plus sign (no edge) data marker.
static int MARKER_TYPE_SIMPLE_TETRAHEDRON
          Flag for a simple tetrahedron (no edge) data marker.
static int MARKER_TYPE_SPHERE
          Flag for a sphere data marker.
static int MARKER_TYPE_TETRAHEDRON
          Flag for a tetrahedron data marker.
static long serialVersionUID
           
 
Fields inherited from class com.imsl.chart.AbstractChartNode
AUTOSCALE_DATA, AUTOSCALE_DENSITY, AUTOSCALE_NUMBER, AUTOSCALE_OFF, AUTOSCALE_WINDOW, AXIS_X, AXIS_Y, AXIS_Z, LABEL_TYPE_NONE, LABEL_TYPE_TITLE, LABEL_TYPE_X, LABEL_TYPE_Y, LABEL_TYPE_Z, TRANSFORM_CUSTOM, TRANSFORM_LINEAR, TRANSFORM_LOG
 
Constructor Summary
ChartNode3D(ChartNode3D parent)
          Construct a ChartNode3D object.
 
Method Summary
protected abstract  void addToSceneGraph(Group parent)
          Called to add this object to the scene graph.
 int getAxisTitlePosition()
          Returns the value of the "AxisTitlePosition" attribute.
 BoundingSphere getBoundingSphere()
          Gets the spherical bounding region object BoundingSphere.
 ChartNode3D[] getChildren()
          Returns an array of the children of this node.
 ColorFunction getColorFunction()
          Returns the value of the "ColorFunction" attribute.
 double[] getConcatenatedViewport()
          Returns the value of the "Viewport" attribute concatenated with the "Viewport" attributes set in its ancestor nodes.
 int getDataType()
          Returns the value of the "DataType" attribute.
 boolean getLightingEnabled()
          Returns the value of the "LightingEnabled" attribute.
 double getMarkerPulsingCycle()
          Returns the value of the "MarkerPulsingCycle" attribute.
 double getMarkerPulsingCycleOffset()
          Returns the value of the "MarkerPulsingCycleOffset" attribute.
 double getMarkerPulsingMaximumScale()
          Returns the value of the "MarkerPulsingMaximumScale" attribute.
 double getMarkerPulsingMinimumScale()
          Returns the value of the "MarkerPulsingMinimumScale" attribute.
 double[] getMarkerRotatingAxis()
          Returns the value of the "MarkerRotatingAxis" attribute.
 double getMarkerRotatingCycle()
          Returns the value of the "MarkerRotatingCycle" attribute.
 double getMarkerRotatingCycleOffset()
          Returns the value of the "MarkerRotatingCycleOffset" attribute.
 int getMarkerType()
          Returns the value of the "MarkerType" attribute.
 Material getMaterial()
          Returns the value of the "Material" attribute.
 ChartNode3D getParent()
          Returns the parent of this node.
 String getTitle()
          Returns the value of the "Title" attribute.
 double[] getViewport()
          Returns the value of the "Viewport" attribute.
 VirtualUniverse getVirtualUniverse()
          Returns the value of the "Universe" attribute.
 double[] getZ()
          Returns the value of the "Z" attribute.
 void setAxisTitlePosition(int value)
          Sets the value of the "AxisTitlePosition" attribute.
 void setBoundingSphere(BoundingSphere bounds)
          Sets the spherical bounding region object BoundingSphere.
 void setColorFunction(ColorFunction colorFunction)
          Sets the value of the "ColorFunction" attribute.
 void setDataType(int value)
          Sets the value of the "DataType" attribute.
 void setLightingEnabled(boolean lightingEnabled)
          Sets the value of the "LightingEnabled" attribute.
 void setMarkerPulsingCycle(double time)
          Sets the value of the "MarkerPulsingCycle" attribute.
 void setMarkerPulsingCycleOffset(double offset)
          Sets the value of the "MarkerPulsingCycleOffset" attribute.
 void setMarkerPulsingMaximumScale(double max)
          Sets the value of the "MarkerPulsingMaximumScale" attribute.
 void setMarkerPulsingMinimumScale(double min)
          Sets the value of the "MarkerPulsingMinimumScale" attribute.
 void setMarkerRotatingAxis(double x, double y, double z)
          Sets the value of the "MarkerRotatingAxis" attribute.
 void setMarkerRotatingCycle(double time)
          Sets the value of the "MarkerRotatingCycle" attribute.
 void setMarkerRotatingCycleOffset(double offset)
          Sets the value of the "MarkerRotatingCycleOffset" attribute.
 void setMarkerType(int type)
          Sets the value of the "MarkerType" attribute.
 void setMaterial(Material material)
          Sets the value of the "Material" attribute.
 void setTitle(String value)
          Sets the value of the "Title" attribute.
 void setViewport(double[] value)
          Sets the value of the "Viewport" attribute.
 void setViewport(double xmin, double xmax, double ymin, double ymax, double zmin, double zmax)
          Sets the value of the "Viewport" attribute.
 void setZ(Object value)
          Sets the value of the "Z" attribute.
 
Methods inherited from class com.imsl.chart.AbstractChartNode
clone, clone, clone, clone, getAbstractParent, getAttribute, getAutoscaleInput, getAutoscaleMinimumTimeInterval, getAutoscaleOutput, getBooleanAttribute, getChildList, getColorAttribute, getCustomTransform, getDensity, getDoubleAttribute, getFillColor, getFont, getFontName, getFontSize, getFontStyle, getImage, getIntegerAttribute, getLabelType, getLightColor, getLineColor, getLineWidth, getLocale, getMarkerColor, getMarkerSize, getName, getNumber, getPaint, getStringAttribute, getTextColor, getTextFormat, getTickLength, getTransform, getX, getY, isAncestorOf, isAttributeSet, isAttributeSetAtThisNode, isBitSet, parseColor, remove, setAttribute, setAutoscaleInput, setAutoscaleMinimumTimeInterval, setAutoscaleOutput, setCustomTransform, setDensity, setFillColor, setFillColor, setFont, setFontName, setFontSize, setFontStyle, setImage, setLabelType, setLightColor, setLightColor, setLineColor, setLineColor, setLineWidth, setLocale, setMarkerColor, setMarkerColor, setMarkerSize, setName, setNumber, setPaint, setTextColor, setTextColor, setTextFormat, setTextFormat, setTickLength, setTransform, setX, setY, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

AXIS_TITLE_AT_END

public static final int AXIS_TITLE_AT_END
Value for attribute "AxisTitlePosition" indicating that the axis title should be placed at the end of the axis.

See Also:
Constant Field Values

AXIS_TITLE_PARALLEL

public static final int AXIS_TITLE_PARALLEL
Value for attribute "AxisTitlePosition" indicating that the axis title should be placed parallel to the axis.

See Also:
Constant Field Values

DATA_TYPE_LINE

public static final int DATA_TYPE_LINE
Value for attribute "DataType" indicating that the data points should be connected with line segments. This is the default setting.

See Also:
Constant Field Values

DATA_TYPE_MARKER

public static final int DATA_TYPE_MARKER
Value for attribute "DataType" indicating that a marker should be drawn at each data point.

See Also:
Constant Field Values

DATA_TYPE_PICTURE

public static final int DATA_TYPE_PICTURE
Value for attribute "DataType" indicating that an image (attribute "Image") should be drawn at each data point. This can be used to draw fancy markers.

See Also:
Constant Field Values

DATA_TYPE_TUBE

public static final int DATA_TYPE_TUBE
Value for attribute "DataType" indicating that a tube connecting the data points should be drawn. Tubes are similar to lines, but tubes are shaded. The diameter of the tube is controlled by the attribute "LineWidth". Tube color is controlled by the attribute "LineColor".

See Also:
Constant Field Values

MARKER_TYPE_CUBE

public static final int MARKER_TYPE_CUBE
Flag for a cube data marker.

See Also:
Constant Field Values

MARKER_TYPE_CUSTOM

public static final int MARKER_TYPE_CUSTOM
Flag for a custom marker

See Also:
Constant Field Values

MARKER_TYPE_PLUS

public static final int MARKER_TYPE_PLUS
Flag for a 3D plus sign data marker.

See Also:
Constant Field Values

MARKER_TYPE_SIMPLE_CUBE

public static final int MARKER_TYPE_SIMPLE_CUBE
Flag for a simple cube (no edge) data marker.

See Also:
Constant Field Values

MARKER_TYPE_SIMPLE_PLUS

public static final int MARKER_TYPE_SIMPLE_PLUS
Flag for a simple 2D plus sign (no edge) data marker.

See Also:
Constant Field Values

MARKER_TYPE_SIMPLE_TETRAHEDRON

public static final int MARKER_TYPE_SIMPLE_TETRAHEDRON
Flag for a simple tetrahedron (no edge) data marker.

See Also:
Constant Field Values

MARKER_TYPE_SPHERE

public static final int MARKER_TYPE_SPHERE
Flag for a sphere data marker.

See Also:
Constant Field Values

MARKER_TYPE_TETRAHEDRON

public static final int MARKER_TYPE_TETRAHEDRON
Flag for a tetrahedron data marker.

See Also:
Constant Field Values

serialVersionUID

public static final long serialVersionUID
See Also:
Constant Field Values
Constructor Detail

ChartNode3D

public ChartNode3D(ChartNode3D parent)
Construct a ChartNode3D object.

Parameters:
parent - the ChartNode3D parent of this object
Method Detail

addToSceneGraph

protected abstract void addToSceneGraph(Group parent)
Called to add this object to the scene graph.

Parameters:
parent - is the node in the scene graph at which this object is to be added.

getAxisTitlePosition

public int getAxisTitlePosition()
Returns the value of the "AxisTitlePosition" attribute.

Returns:
The int value of the "AxisTitlePosition" attribute, if defined. Otherwise, AXIS_TITLE_AT_END is returned.

getBoundingSphere

public BoundingSphere getBoundingSphere()
Gets the spherical bounding region object BoundingSphere.

Returns:
a BoundingSphere object which is defined by a centerpoint and a radius.

getChildren

public final ChartNode3D[] getChildren()
Returns an array of the children of this node. If there are no children, a 0-length array is returned.

Returns:
a ChartNode3D array which contains the children of this node

getColorFunction

public ColorFunction getColorFunction()
Returns the value of the "ColorFunction" attribute.

Returns:
The ColorFunction value of the "ColorFunction" attribute, if defined. If not defined null is returned.

getConcatenatedViewport

public double[] getConcatenatedViewport()
Returns the value of the "Viewport" attribute concatenated with the "Viewport" attributes set in its ancestor nodes.

Returns:
a double[4] array containing xmin, xmax, ymin, ymax, zmin, zmax

getDataType

public int getDataType()
Returns the value of the "DataType" attribute.

Returns:
The int value of the "DataType" attribute, if defined. Otherwise, DATA_TYPE_MARKER is returned.

getLightingEnabled

public boolean getLightingEnabled()
Returns the value of the "LightingEnabled" attribute.

Returns:
true if lights are to be used. Its default value is true.

getMarkerPulsingCycle

public double getMarkerPulsingCycle()
Returns the value of the "MarkerPulsingCycle" attribute.

Returns:
The double value of the "MarkerPulsingCycle" attribute, if defined. Otherwise, a default of 0.0 is returned.

getMarkerPulsingCycleOffset

public double getMarkerPulsingCycleOffset()
Returns the value of the "MarkerPulsingCycleOffset" attribute.

Returns:
The double value of the "MarkerPulsingCycleOffset" attribute, if defined. Otherwise, a default of 0.0 is returned.

getMarkerPulsingMaximumScale

public double getMarkerPulsingMaximumScale()
Returns the value of the "MarkerPulsingMaximumScale" attribute.

Returns:
The double value of the "MarkerPulsingMaximumScale" attribute, if defined. Otherwise, a default of 2.0 is returned.

getMarkerPulsingMinimumScale

public double getMarkerPulsingMinimumScale()
Returns the value of the "MarkerPulsingMinimumScale" attribute.

Returns:
The double value of the "MarkerPulsingMinimumScale" attribute, if defined. Otherwise, a default of 0.0 is returned.

getMarkerRotatingAxis

public double[] getMarkerRotatingAxis()
Returns the value of the "MarkerRotatingAxis" attribute.

Returns:
The double value of the "MarkerRotatingAxis" attribute, if defined. Otherwise, a default of 0.0 is returned.

getMarkerRotatingCycle

public double getMarkerRotatingCycle()
Returns the value of the "MarkerRotatingCycle" attribute.

Returns:
The double value of the "MarkerRotatingCycle" attribute, if defined. Otherwise, a default of 0.0 is returned.

getMarkerRotatingCycleOffset

public double getMarkerRotatingCycleOffset()
Returns the value of the "MarkerRotatingCycleOffset" attribute.

Returns:
The double value of the "MarkerRotatingCycleOffset" attribute, if defined. Otherwise, a default of 0.0 is returned.

getMarkerType

public int getMarkerType()
Returns the value of the "MarkerType" attribute.

Returns:
The int value of the "MarkerType" attribute, if defined. Otherwise, a default of MARKER_TYPE_CUBE is returned.

getMaterial

public Material getMaterial()
Returns the value of the "Material" attribute.

Returns:
The value of the "Material" attribute, if defined. Otherwise, a default of material is returned.

getParent

public ChartNode3D getParent()
Returns the parent of this node. Note that this is not an attribute setting. Note that there is no setParent function.

Returns:
A ChartNode3D object which contains this node's parent. This is null in the case of the root node of the chart tree, since that node has no parent.

getTitle

public String getTitle()
Returns the value of the "Title" attribute.

Returns:
the String value of the "Title" attribute

getViewport

public double[] getViewport()
Returns the value of the "Viewport" attribute.

Returns:
a double[6] array containing xmin, xmax, ymin, ymax, zmin, zmax

getVirtualUniverse

public VirtualUniverse getVirtualUniverse()
Returns the value of the "Universe" attribute.

Returns:
The value of the "Universe" attribute.

getZ

public double[] getZ()
Returns the value of the "Z" attribute.

Returns:
the double array which contains the value of the "Z" attribute

setAxisTitlePosition

public void setAxisTitlePosition(int value)
Sets the value of the "AxisTitlePosition" attribute.

Parameters:
value - "AxisTitlePosition" value. This should be AXIS_TITLE_AT_END or AXIS_TITLE_PARALLEL. AXIS_TITLE_AT_END is the default value.

setBoundingSphere

public void setBoundingSphere(BoundingSphere bounds)
Sets the spherical bounding region object BoundingSphere.

Parameters:
bounds - a BoundingSphere object which is defined by a centerpoint and a radius.

setColorFunction

public void setColorFunction(ColorFunction colorFunction)
Sets the value of the "ColorFunction" attribute. ColorFunction defines a value-dependent coloring.

Parameters:
colorFunction - defines a mapping from x,y,z to a color.

setDataType

public void setDataType(int value)
Sets the value of the "DataType" attribute.

Parameters:
value - "DataType" value. This should be some xor-ed combination of DATA_TYPE_LINE, DATA_TYPE_MARKER.

setLightingEnabled

public void setLightingEnabled(boolean lightingEnabled)
Sets the value of the "LightingEnabled" attribute.

Parameters:
lightingEnabled - is true if lights are to be used. Its default value is true.

setMarkerPulsingCycle

public void setMarkerPulsingCycle(double time)
Sets the value of the "MarkerPulsingCycle" attribute. The default marker cycle time is zero. If "MarkerPulsingCycle" is greater then zero then markers pulse with the specified cycle time.

Parameters:
time - a double which specifies the "MarkerPulsingCycle" time in seconds.

setMarkerPulsingCycleOffset

public void setMarkerPulsingCycleOffset(double offset)
Sets the value of the "MarkerPulsingCycleOffset" attribute.

Parameters:
offset - a double which specifies the "MarkerPulsingCycleOffset". This is the time, in seconds, by which a pulsing marker starting time is offset from the initial time. This allows different markers to pulse with different phases.

setMarkerPulsingMaximumScale

public void setMarkerPulsingMaximumScale(double max)
Sets the value of the "MarkerPulsingMaximumScale" attribute.

Parameters:
max - a double which specifies the "MarkerPulsingMaximumScale". This is the amount by which a pulsing marker is scaled at the top of a pulse. Its default value is 2.0.

setMarkerPulsingMinimumScale

public void setMarkerPulsingMinimumScale(double min)
Sets the value of the "MarkerPulsingMinimumScale" attribute.

Parameters:
min - a double which specifies the "MarkerPulsingMinimumScale". This is the amount by which a pulsing marker is scaled at the bottom of a pulse. Its default value is 0.0.

setMarkerRotatingAxis

public void setMarkerRotatingAxis(double x,
                                  double y,
                                  double z)
Sets the value of the "MarkerRotatingAxis" attribute. The default marker cycle time is zero. If "MarkerRotatingAxis" is greater then zero then markers rotate with the specified cycle time.

Parameters:
x - is the x-coordinate of the rotation axis.
y - is the y-coordinate of the rotation axis.
z - is the z-coordinate of the rotation axis.

setMarkerRotatingCycle

public void setMarkerRotatingCycle(double time)
Sets the value of the "MarkerRotatingCycle" attribute. The default marker cycle time is zero. If "MarkerRotatingCycle" is greater then zero then markers rotate with the specified cycle time.

Parameters:
time - a double which specifies the "MarkerRotatingCycle" time in seconds.

setMarkerRotatingCycleOffset

public void setMarkerRotatingCycleOffset(double offset)
Sets the value of the "MarkerRotatingCycleOffset" attribute.

Parameters:
offset - a double which specifies the "MarkerRotatingCycleOffset". This is the time, in seconds, by which a rotating marker starting time is offset from the initial time. This allows different markers to rotate with different phases.

setMarkerType

public void setMarkerType(int type)
Sets the value of the "MarkerType" attribute. This indicates which marker is to be drawn.

Parameters:
type - the int "MarkerType" value.
See Also:
MARKER_TYPE_CUBE, MARKER_TYPE_SIMPLE_CUBE, MARKER_TYPE_SPHERE, MARKER_TYPE_TETRAHEDRON, MARKER_TYPE_SIMPLE_TETRAHEDRON, MARKER_TYPE_PLUS, MARKER_TYPE_SIMPLE_PLUS, MARKER_TYPE_CUSTOM

setMaterial

public void setMaterial(Material material)
Sets the value of the "Material" attribute. This indicates which matherial is to be used when lighting a surface.

Parameters:
material - is a Java 3D Material value.

setTitle

public void setTitle(String value)
Sets the value of the "Title" attribute.

Parameters:
value - a String which contains the "Title" value

setViewport

public void setViewport(double[] value)
Sets the value of the "Viewport" attribute. The viewport is the subregion of the drawing surface where the plot is to be drawn. "Viewport" coordinates are [0,1] by [0,1] by [0,1] This attribute affects only Axis nodes, since they contain the mappings to device space.

Parameters:
value - A double array of length 6 which contains the "Viewport" values for xmin, xmax, ymin, ymax, zmin, zmax. The value saved is a copy of the input array.
See Also:
Axis

setViewport

public void setViewport(double xmin,
                        double xmax,
                        double ymin,
                        double ymax,
                        double zmin,
                        double zmax)
Sets the value of the "Viewport" attribute.

Parameters:
xmin - a double, the minimum x-coordinate of the viewport
xmax - a double, the maximum x-coordinate of the viewport
ymin - a double, the minimum y-coordinate of the viewport
ymax - a double, the maximum y-coordinate of the viewport
zmin - a double, the minimum z-coordinate of the viewport
zmax - a double, the maximum z-coordinate of the viewport

setZ

public void setZ(Object value)
Sets the value of the "Z" attribute.

Parameters:
value - the Object which contains the "Z" value

JMSLTM Numerical Library 5.0.1

Copyright © 1970-2008 Visual Numerics, Inc.
Built July 8 2008.