|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectedu.uthscsa.ric.visualization.SurfaceData
public class SurfaceData
SurfaceData is a container for surface-related data.
Constructor Summary | |
---|---|
SurfaceData(float[] points,
float[] normals,
int[] triangles,
float[] rotation,
float[] zoom,
float[] zoomScroll,
float[] translation,
String name,
float[] color,
boolean asIndices)
Constructor. |
|
SurfaceData(J3DBuffer points,
J3DBuffer normals,
int[] triangles,
boolean asIndices)
Constructor. |
|
SurfaceData(J3DBuffer points,
J3DBuffer normals,
int[] triangles,
float[] rotation,
boolean asIndices)
Constructor. |
|
SurfaceData(J3DBuffer points,
J3DBuffer normals,
int[] triangles,
float[] rotation,
float[] zoom,
float[] zoomScroll,
float[] translation,
String name,
float[] color,
boolean asIndices)
Constructor. |
|
SurfaceData(J3DBuffer points,
J3DBuffer normals,
int[] triangles,
float[] rotation,
String name,
float[] color,
boolean asIndices)
Constructor. |
Method Summary | |
---|---|
void |
convertStripCountsToIndices()
Converts triangle data as strip counts to point indices. |
float[] |
getColor()
Returns a three float array of RGB values representing the surface color. |
String |
getFormat()
Returns a string representing the surface file format. |
int[] |
getImageDims()
Returns image dimensions. |
String |
getName()
Returns the name of this surface. |
double[] |
getNormal(double[] normal,
int offset)
Gets normal from normal buffer. |
Vector3d |
getNormal(Vector3d normal,
int offset)
Gets normal from normal buffer. |
float[] |
getNormalsArray()
Returns the normals buffer. |
J3DBuffer |
getNormalsBuffer()
Returns the normals buffer. |
double |
getNormalValue(int offset)
Returns a normal value. |
int |
getNumPointValues()
Returns number of stored point values (num points * 3). |
Coordinate |
getOrigin()
Returns the image origin. |
double[] |
getPoint(double[] point,
int offset)
Gets point from point buffer. |
Point3d |
getPoint(Point3d point,
int offset)
Gets point from point buffer. |
float[] |
getPointsArray()
Returns the points buffer. |
J3DBuffer |
getPointsBuffer()
Returns the points buffer. |
double |
getPointValue(int offset)
Returns a point value. |
float[] |
getRotationTransform()
Returns the rotation transform. |
float |
getScalarMax()
Returns the value associated with the upper end of the color table. |
float |
getScalarMin()
Returns the value associated with the lower end of the color table. |
ShapeData[] |
getShapeData()
Returns line and point shape data. |
Vector<SurfaceOverlay> |
getSurfaceOverlays()
Returns overlay data associated with this surface. |
float[] |
getTransform()
Deprecated. use getRotationTransform() |
float[] |
getTranslationTransform()
Returns the translation transform. |
int[] |
getTriangles()
Returns the triangle data. |
float[] |
getVoxelDims()
Returns voxel dimensions. |
float[] |
getZoomScrollTransform()
Returns the zoom scroll transform. |
float[] |
getZoomTransform()
Returns the zoom transform. |
boolean |
isIndices()
Returns true if the triangle data represents point indices, false if it represents strip counts |
void |
setFormat(String format)
Sets the surface file format string. |
void |
setImageDims(int[] dims)
Sets image dimensions. |
void |
setOrigin(Coordinate coor)
Sets the image origin. |
void |
setScalarRange(float min,
float max)
Sets the scalar value range associated with the color table. |
void |
setShapeData(ShapeData[] data)
Sets line and point shape data. |
void |
setSurfaceOverlays(Vector<SurfaceOverlay> overlays)
Sets the surface overlay data used by this surface. |
void |
setVoxelDims(float[] dims)
Sets voxel dimensions. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SurfaceData(J3DBuffer points, J3DBuffer normals, int[] triangles, boolean asIndices)
points
- points buffer (J3DBuffer contains a java.nio.FloatBuffer)normals
- normals buffer (J3DBuffer contains a java.nio.FloatBuffer)triangles
- triangles arrayasIndices
- true if the triangle array contains point indices describing triangles, false if it contains strip countspublic SurfaceData(J3DBuffer points, J3DBuffer normals, int[] triangles, float[] rotation, boolean asIndices)
points
- points buffer (J3DBuffer contains a java.nio.FloatBuffer)normals
- normals buffer (J3DBuffer contains a java.nio.FloatBuffer)triangles
- triangles arrayrotation
- a 4x4 rotation transformasIndices
- true if the triangle array contains point indices describing triangles, false if it contains strip countspublic SurfaceData(J3DBuffer points, J3DBuffer normals, int[] triangles, float[] rotation, String name, float[] color, boolean asIndices)
points
- points buffer (J3DBuffer contains a java.nio.FloatBuffer)normals
- normals buffer (J3DBuffer contains a java.nio.FloatBuffer)triangles
- triangles arrayrotation
- a 4x4 rotation transformname
- the surface namecolor
- a three float array containing RGB valuesasIndices
- true if the triangle array contains point indices describing triangles, false if it contains strip countspublic SurfaceData(J3DBuffer points, J3DBuffer normals, int[] triangles, float[] rotation, float[] zoom, float[] zoomScroll, float[] translation, String name, float[] color, boolean asIndices)
points
- points buffer (J3DBuffer contains a java.nio.FloatBuffer)normals
- normals buffer (J3DBuffer contains a java.nio.FloatBuffer)triangles
- triangles arrayrotation
- a 4x4 rotation transformzoom
- a 4x4 zoom transform (z translation)zoomScroll
- a 4x4 zoom scroll transform (z translation)translation
- a 4x4 translation transform (x and y translation)name
- the surface namecolor
- a three float array containing RGB valuesasIndices
- true if the triangle array contains point indices describing triangles, false if it contains strip countspublic SurfaceData(float[] points, float[] normals, int[] triangles, float[] rotation, float[] zoom, float[] zoomScroll, float[] translation, String name, float[] color, boolean asIndices)
points
- points array (used in Java3D v1.3)normals
- normals array (used in Java3D v1.3)triangles
- triangles arrayrotation
- a 4x4 rotation transformzoom
- a 4x4 zoom transform (z translation)zoomScroll
- a 4x4 zoom scroll transform (z translation)translation
- a 4x4 translation transform (x and y translation)name
- the surface namecolor
- a three float array containing RGB valuesasIndices
- true if the triangle array contains point indices describing triangles, false if it contains strip countsMethod Detail |
---|
public Point3d getPoint(Point3d point, int offset)
point
- a Point3d pointoffset
-
public double[] getPoint(double[] point, int offset)
point
- a double array of length 3offset
-
public double getPointValue(int offset)
offset
-
public Vector3d getNormal(Vector3d normal, int offset)
normal
- a Vector3d normaloffset
-
public double[] getNormal(double[] normal, int offset)
normal
- a double array of length 3offset
-
public double getNormalValue(int offset)
offset
-
public J3DBuffer getPointsBuffer()
public J3DBuffer getNormalsBuffer()
public float[] getPointsArray()
public float[] getNormalsArray()
public int getNumPointValues()
public int[] getTriangles()
public float[] getTransform()
public float[] getRotationTransform()
public float[] getZoomTransform()
public float[] getZoomScrollTransform()
public float[] getTranslationTransform()
public boolean isIndices()
public String getName()
public float[] getColor()
public Vector<SurfaceOverlay> getSurfaceOverlays()
public void setSurfaceOverlays(Vector<SurfaceOverlay> overlays)
overlays
- a vector containing surface overlay datapublic void setScalarRange(float min, float max)
min
- the value associated with the lower end of the color tablemax
- the value associated with the upper end of the color tablepublic float getScalarMin()
public float getScalarMax()
public ShapeData[] getShapeData()
public void setShapeData(ShapeData[] data)
data
- an array of line and point shape datapublic void convertStripCountsToIndices()
public void setVoxelDims(float[] dims)
dims
- voxel dimensionspublic float[] getVoxelDims()
public void setImageDims(int[] dims)
dims
- image dimensionspublic int[] getImageDims()
public void setOrigin(Coordinate coor)
coor
- image originpublic Coordinate getOrigin()
public String getFormat()
public void setFormat(String format)
format
- file format
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |