org.scilab.forge.scirenderer.shapes.geometry
Class DefaultGeometry

java.lang.Object
  extended by org.scilab.forge.scirenderer.shapes.geometry.DefaultGeometry
All Implemented Interfaces:
Geometry

public class DefaultGeometry
extends java.lang.Object
implements Geometry

Default implementation of a Geometry.

Author:
Pierre Lando

Nested Class Summary
 
Nested classes/interfaces inherited from interface org.scilab.forge.scirenderer.shapes.geometry.Geometry
Geometry.FaceCullingMode, Geometry.FillDrawingMode, Geometry.LineDrawingMode
 
Field Summary
 
Fields inherited from interface org.scilab.forge.scirenderer.shapes.geometry.Geometry
DEFAULT_FACE_CULLING_MODE, DEFAULT_FILL_DRAWING_MODE, DEFAULT_LINE_DRAWING_MODE, DEFAULT_POLYGON_OFFSET_MODE
 
Constructor Summary
DefaultGeometry()
          Default constructor.
 
Method Summary
 ElementsBuffer getColors()
          Return the colors.
 Geometry.FaceCullingMode getFaceCullingMode()
          Face-culling mode getter.
 Geometry.FillDrawingMode getFillDrawingMode()
          Fill drawing mode getter.
 IndicesBuffer getIndices()
          Return the indices if any.
 Geometry.LineDrawingMode getLineDrawingMode()
          Line drawing mode getter.
 ElementsBuffer getNormals()
          Return the normals.
 boolean getPolygonOffsetMode()
          Polygon offset mode getter.
 ElementsBuffer getTextureCoordinates()
          Texture coordinates getter.
 ElementsBuffer getVertices()
          Return the vertices.
 IndicesBuffer getWireIndices()
          Return the wire indices.
 void setColors(ElementsBuffer colors)
          Colors setter.
 void setFaceCullingMode(Geometry.FaceCullingMode faceCullingMode)
          Face culling mode setter.
 void setFillDrawingMode(Geometry.FillDrawingMode fillDrawingMode)
          Fill drawing mode setter.
 void setIndices(IndicesBuffer indicesBuffer)
          Indices setter.
 void setLineDrawingMode(Geometry.LineDrawingMode lineDrawingMode)
          Line drawing mode setter.
 void setNormals(ElementsBuffer normals)
          Normals setter.
 void setPolygonOffsetMode(boolean polygonOffsetMode)
          Polygon offset mode setter.
 void setTextureCoordinates(ElementsBuffer textureCoordinates)
          Texture coordinates setter.
 void setVertices(ElementsBuffer vertices)
          Vertices setter.
 void setWireIndices(IndicesBuffer wireIndices)
          Wire indices setter.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultGeometry

public DefaultGeometry()
Default constructor.

Method Detail

getFaceCullingMode

public final Geometry.FaceCullingMode getFaceCullingMode()
Description copied from interface: Geometry
Face-culling mode getter.

Specified by:
getFaceCullingMode in interface Geometry
Returns:
the face culling mode.

getFillDrawingMode

public final Geometry.FillDrawingMode getFillDrawingMode()
Description copied from interface: Geometry
Fill drawing mode getter.

Specified by:
getFillDrawingMode in interface Geometry
Returns:
the fill-drawing mode for this object.

getLineDrawingMode

public final Geometry.LineDrawingMode getLineDrawingMode()
Description copied from interface: Geometry
Line drawing mode getter.

Specified by:
getLineDrawingMode in interface Geometry
Returns:
the line drawing mode.

getPolygonOffsetMode

public final boolean getPolygonOffsetMode()
Description copied from interface: Geometry
Polygon offset mode getter.

Specified by:
getPolygonOffsetMode in interface Geometry
Returns:
the polygon offset mode.

getVertices

public final ElementsBuffer getVertices()
Description copied from interface: Geometry
Return the vertices.

Specified by:
getVertices in interface Geometry
Returns:
the vertices.

getIndices

public final IndicesBuffer getIndices()
Description copied from interface: Geometry
Return the indices if any. If null is returned, indices should be treated as consecutive number.

Specified by:
getIndices in interface Geometry
Returns:
the indices.

getWireIndices

public final IndicesBuffer getWireIndices()
Description copied from interface: Geometry
Return the wire indices. If null is returned, no edges are drawn.

Specified by:
getWireIndices in interface Geometry
Returns:
the edges indices.

getColors

public final ElementsBuffer getColors()
Description copied from interface: Geometry
Return the colors.

Specified by:
getColors in interface Geometry
Returns:
the colors.

getTextureCoordinates

public final ElementsBuffer getTextureCoordinates()
Description copied from interface: Geometry
Texture coordinates getter.

Specified by:
getTextureCoordinates in interface Geometry
Returns:
the texture coordinate.

getNormals

public final ElementsBuffer getNormals()
Description copied from interface: Geometry
Return the normals.

Specified by:
getNormals in interface Geometry
Returns:
the normals.

setFaceCullingMode

public final void setFaceCullingMode(Geometry.FaceCullingMode faceCullingMode)
Face culling mode setter.

Parameters:
faceCullingMode - the new face culling mode.

setFillDrawingMode

public final void setFillDrawingMode(Geometry.FillDrawingMode fillDrawingMode)
Fill drawing mode setter.

Parameters:
fillDrawingMode - the new fill drawing mode.

setLineDrawingMode

public final void setLineDrawingMode(Geometry.LineDrawingMode lineDrawingMode)
Line drawing mode setter.

Parameters:
lineDrawingMode - the new line drawing mode.

setPolygonOffsetMode

public final void setPolygonOffsetMode(boolean polygonOffsetMode)
Polygon offset mode setter.

Parameters:
polygonOffsetMode - the new polygon offset mode.

setTextureCoordinates

public final void setTextureCoordinates(ElementsBuffer textureCoordinates)
Texture coordinates setter.

Parameters:
textureCoordinates - the new texture coordinate data.

setVertices

public final void setVertices(ElementsBuffer vertices)
Vertices setter.

Parameters:
vertices - the new vertices data.

setNormals

public final void setNormals(ElementsBuffer normals)
Normals setter.

Parameters:
normals - the new normals data.

setColors

public final void setColors(ElementsBuffer colors)
Colors setter.

Parameters:
colors - the new colors data.

setWireIndices

public final void setWireIndices(IndicesBuffer wireIndices)
Wire indices setter.

Parameters:
wireIndices - the new wire indices data.

setIndices

public final void setIndices(IndicesBuffer indicesBuffer)
Indices setter.

Parameters:
indicesBuffer - the new indices data.