org.xith3d.scenegraph
Class GeometryArray
java.lang.Object
org.xith3d.scenegraph.SceneGraphObject
org.xith3d.scenegraph.NodeComponent
org.xith3d.scenegraph.Geometry
org.xith3d.scenegraph.GeomContainer
org.xith3d.scenegraph.GeometryArray
- All Implemented Interfaces:
- org.jagatoo.datatypes.NamableObject, org.jagatoo.datatypes.NamedObject, org.openmali.spatial.VertexContainer
- Direct Known Subclasses:
- GeometryStripArray, GeomIndexedContainer, LineArray, PointArray, QuadArray, TriangleArray
public abstract class GeometryArray
- extends GeomContainer
GeometryArray defines attributes that apply to .
| Fields inherited from class org.xith3d.scenegraph.GeomContainer |
BY_REFERENCE, colors, COLORS, COORDINATES, coords, faceSize, INTERLEAVED, interleavedData, normals, NORMALS, numVertices, texCoords, TEXTURE_COORDINATES, VERTEX_ATTRIBUTES, vertexAttribs |
|
Method Summary |
abstract GeometryArray |
cloneNodeComponent(boolean forceDuplicate)
|
protected void |
duplicateNodeComponent(NodeComponent original,
boolean forceDuplicate)
|
boolean |
getTriangle(int i0,
int i1,
int i2,
org.openmali.spatial.polygons.Triangle triangle)
Retrieves the the n-th Triangle from the GeometryArray. |
boolean |
setTriangle(int i0,
int i1,
int i2,
org.openmali.spatial.polygons.Triangle triangle)
Applies the the n-th Triangle to the GeometryArray. |
boolean |
setTriangle(org.openmali.spatial.polygons.Triangle triangle)
Applies the the n-th Triangle to the GeometryArray. |
| Methods inherited from class org.xith3d.scenegraph.GeomContainer |
addData, addData, addData, calculateFaceNormals, calculateFaceNormals, finalize, flipNormals, freeOpenGLResources, getColor, getColor, getColorData, getColorRefFloat, getColors, getColorsOffset, getColorsSize, getCoordinate, getCoordinate, getCoordinates, getCoordinates, getCoordinatesData, getCoordinatesOffset, getCoordinatesSize, getCoordRefFloat, getFaceSize, getInitialVertexIndex, getInterleavedData, getNormal, getNormal, getNormalRefFloat, getNormals, getNormals, getNormalsData, getNormalsOffset, getNormalsSize, getOpenGLReference_DL_GeomData, getOpenGLReference_DL_TexCoords, getOpenGLReference_DL, getTexCoordRefFloat, getTexCoordsData, getTexCoordSetCount, getTexCoordSetMap, getTexCoordSetMap, getTexCoordSize, getTexCoordsOffset, getTextureCoordinate, getTextureCoordinate, getTextureCoordinate, getTextureCoordinate, getTextureCoordinate, getTextureCoordinates, getType, getValidVertexCount, getVertex, getVertexAttribData, getVertexAttribSize, getVertexAttribsOffset, getVertexAttribute, getVertexAttribute, getVertexAttribute, getVertexAttribute, getVertexAttribute, getVertexAttributes, getVertexAttributesCount, getVertexCount, getVertexFormat, hasColorAlpha, hasColors, hasFeature, hasIndex, hasNormals, hasTextureCoordinates, hasTextureCoordinates, hasVertexAttributes, hasVertexAttributes, invertNormals, isInterleaved, isStrip, makeInterleaved, makeInterleaved, setColor, setColor, setColor, setColor, setColorData, setColors, setColors, setColors, setColors, setCoordinate, setCoordinate, setCoordinate, setCoordinateData, setCoordinates, setCoordinates, setCoordinates, setCoordinates, setDataBuffers, setInitialVertexIndex, setNioBuffers, setNormal, setNormal, setNormal, setNormalData, setNormals, setNormals, setNormals, setNormals, setTexCoordData, setTextureCoordinate, setTextureCoordinate, setTextureCoordinate, setTextureCoordinate, setTextureCoordinate, setTextureCoordinate, setTextureCoordinate, setTextureCoordinate, setTextureCoordinates, setTextureCoordinates, setTextureCoordinates, setTextureCoordinates, setTextureCoordinates, setTextureCoordinates, setTextureCoordinates, setTextureCoordinates, setValidVertexCount, setVertexAttribute, setVertexAttribute, setVertexAttribute, setVertexAttribute, setVertexAttribute, setVertexAttributes, setVertexAttributes, setVertexAttributes, setVertexAttributes, setVertexAttributes, setVertexAttributes, setVertexAttributes, setVertexAttributes, update, updateData |
| Methods inherited from class org.xith3d.scenegraph.SceneGraphObject |
getName, getUserData, getUserData, getUserDataMap, isLive, setLive, setName, setUserData, setUserData, setUserDataRecursive, setUserDataRecursive, toString |
| Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
GeometryArray
public GeometryArray(GeomContainer.Type type,
int coordsSize,
int vertexCount,
int[] stripVertexCounts)
setTriangle
public boolean setTriangle(int i0,
int i1,
int i2,
org.openmali.spatial.polygons.Triangle triangle)
- Applies the the n-th Triangle to the GeometryArray.
This method must be overridden by concrete classes to fix the vertex-index (e.g. for an IndexedTriangleArray)
- Parameters:
i0 - the first triangle's vertex-indexi1 - the second triangle's vertex-indexi2 - the third triangle's vertex-indextriangle -
- Returns:
- true, if the triangle could be applied
setTriangle
public boolean setTriangle(org.openmali.spatial.polygons.Triangle triangle)
- Applies the the n-th Triangle to the GeometryArray.
This method must be overridden by concrete classes to fix the vertex-index (e.g. for an IndexedTriangleArray)
- Parameters:
triangle -
- Returns:
- true, if the triangle could be applied
getTriangle
public boolean getTriangle(int i0,
int i1,
int i2,
org.openmali.spatial.polygons.Triangle triangle)
- Retrieves the the n-th Triangle from the GeometryArray.
This method must be overridden by concrete classes to fix the vertex-index (e.g. for an IndexedTriangleArray)
- Parameters:
i0 - the first triangle's vertex-indexi1 - the second triangle's vertex-indexi2 - the third triangle's vertex-indextriangle -
- Returns:
- true, if the triangle could be retrieved
duplicateNodeComponent
protected void duplicateNodeComponent(NodeComponent original,
boolean forceDuplicate)
-
- Overrides:
duplicateNodeComponent in class GeomContainer
cloneNodeComponent
public abstract GeometryArray cloneNodeComponent(boolean forceDuplicate)
-
- Specified by:
cloneNodeComponent in class Geometry