NASA World Wind

gov.nasa.worldwind.render
Class ExtrudedPolygon.ShapeData

java.lang.Object
  extended by gov.nasa.worldwind.avlist.AVListImpl
      extended by gov.nasa.worldwind.cache.ShapeDataCache.ShapeDataCacheEntry
          extended by gov.nasa.worldwind.render.AbstractShape.AbstractShapeData
              extended by gov.nasa.worldwind.render.ExtrudedPolygon.ShapeData
All Implemented Interfaces:
AVList, Iterable<ExtrudedPolygon.ExtrudedBoundaryInfo>
Enclosing class:
ExtrudedPolygon

protected static class ExtrudedPolygon.ShapeData
extends AbstractShape.AbstractShapeData
implements Iterable<ExtrudedPolygon.ExtrudedBoundaryInfo>

The ShapeData class holds globe-specific data for this shape.


Field Summary
protected  List<ExtrudedPolygon.ExtrudedBoundaryInfo> boundaries
          The boundary locations of the associated shape.
protected  List<IntBuffer> capFillIndexBuffers
          Slices of capFillIndices, one per boundary.
protected  IntBuffer capFillIndices
          The indices identifying the cap vertices in a shape data's vertex buffer.
protected  FloatBuffer capNormalBuffer
          A buffer holding the cap normals of all the shape's boundaries.
protected  FloatBuffer capVertexBuffer
          A buffer holding the Cartesian cap vertices of all the shape's boundaries.
protected  GLUTessellatorSupport.CollectIndexListsCallback cb
          This shape's tessellation.
protected  FloatBuffer sideNormalBuffer
          A buffer holding the side normals of all the shape's boundaries.
protected  FloatBuffer sideTextureCoordsBuffer
          A buffer holding the texture coordinates of all the shape's faces.
protected  FloatBuffer sideVertexBuffer
          A buffer holding the Cartesian vertices of all the shape's side vertices.
protected  boolean tessellationError
          Indicates whether a tessellation error occurred.
 
Fields inherited from class gov.nasa.worldwind.render.AbstractShape.AbstractShapeData
frameNumber, referenceDistance, referencePoint, vboCacheKey
 
Fields inherited from class gov.nasa.worldwind.cache.ShapeDataCache.ShapeDataCacheEntry
extent, eyeDistance, globeStateKey, lastUsed, timer, verticalExaggeration
 
Constructor Summary
ExtrudedPolygon.ShapeData(DrawContext dc, ExtrudedPolygon shape)
          Constructs an instance using the boundaries of a specified extruded polygon.
 
Method Summary
protected  void copySideTextureReferences(ExtrudedPolygon shape)
           
protected  ExtrudedPolygon.ExtrudedBoundaryInfo getOuterBoundaryInfo()
          Returns the outer boundary information for this shape data.
 Iterator<ExtrudedPolygon.ExtrudedBoundaryInfo> iterator()
          Iterates over the boundary information of this shape data.
 
Methods inherited from class gov.nasa.worldwind.render.AbstractShape.AbstractShapeData
getFrameNumber, getReferenceDistance, getReferencePoint, getVboCacheKey, setFrameNumber, setReferenceDistance, setReferencePoint, setVboCacheKey
 
Methods inherited from class gov.nasa.worldwind.cache.ShapeDataCache.ShapeDataCacheEntry
getExtent, getEyeDistance, getGlobeStateKey, getTimer, getVerticalExaggeration, isExpired, isValid, restartTimer, setExpired, setExtent, setEyeDistance, setGlobeStateKey, setTimer, setVerticalExaggeration
 
Methods inherited from class gov.nasa.worldwind.avlist.AVListImpl
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getBooleanValue, getBooleanValue, getChangeSupport, getDoubleValue, getDoubleValue, getEntries, getIntegerValue, getIntegerValue, getLongValue, getLongValue, getRestorableStateForAVPair, getStringValue, getStringValue, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

boundaries

protected List<ExtrudedPolygon.ExtrudedBoundaryInfo> boundaries
The boundary locations of the associated shape. Copied from that shape during construction.


capFillIndexBuffers

protected List<IntBuffer> capFillIndexBuffers
Slices of capFillIndices, one per boundary.


capFillIndices

protected IntBuffer capFillIndices
The indices identifying the cap vertices in a shape data's vertex buffer. Determined when this shape is tessellated, which occurs only once unless the shape's boundaries are re-specified.


capNormalBuffer

protected FloatBuffer capNormalBuffer
A buffer holding the cap normals of all the shape's boundaries.


capVertexBuffer

protected FloatBuffer capVertexBuffer
A buffer holding the Cartesian cap vertices of all the shape's boundaries.


cb

protected GLUTessellatorSupport.CollectIndexListsCallback cb
This shape's tessellation.


sideNormalBuffer

protected FloatBuffer sideNormalBuffer
A buffer holding the side normals of all the shape's boundaries.


sideTextureCoordsBuffer

protected FloatBuffer sideTextureCoordsBuffer
A buffer holding the texture coordinates of all the shape's faces. Non-null only when texture is applied.


sideVertexBuffer

protected FloatBuffer sideVertexBuffer
A buffer holding the Cartesian vertices of all the shape's side vertices.


tessellationError

protected boolean tessellationError
Indicates whether a tessellation error occurred. No more attempts to tessellate will be made if set to true.

Constructor Detail

ExtrudedPolygon.ShapeData

public ExtrudedPolygon.ShapeData(DrawContext dc,
                                 ExtrudedPolygon shape)
Constructs an instance using the boundaries of a specified extruded polygon.

Parameters:
dc - the current draw context.
shape - this shape.
Method Detail

copySideTextureReferences

protected void copySideTextureReferences(ExtrudedPolygon shape)

getOuterBoundaryInfo

protected ExtrudedPolygon.ExtrudedBoundaryInfo getOuterBoundaryInfo()
Returns the outer boundary information for this shape data.

Returns:
this shape data's outer boundary information.

iterator

public Iterator<ExtrudedPolygon.ExtrudedBoundaryInfo> iterator()
Iterates over the boundary information of this shape data.

Specified by:
iterator in interface Iterable<ExtrudedPolygon.ExtrudedBoundaryInfo>
Returns:
an iterator over this shape data's boundary info.

NASA World Wind