NASA World Wind

gov.nasa.worldwind.render
Class SurfaceEllipse

java.lang.Object
  extended by gov.nasa.worldwind.avlist.AVListImpl
      extended by gov.nasa.worldwind.render.AbstractSurfaceObject
          extended by gov.nasa.worldwind.render.AbstractSurfaceShape
              extended by gov.nasa.worldwind.render.SurfaceConcaveShape
                  extended by gov.nasa.worldwind.render.SurfaceEllipse
All Implemented Interfaces:
AVList, MeasurableArea, MeasurableLength, Movable, PreRenderable, Renderable, SurfaceObject, SurfaceShape, Restorable
Direct Known Subclasses:
SurfaceCircle

public class SurfaceEllipse
extends SurfaceConcaveShape


Nested Class Summary
 
Nested classes/interfaces inherited from class gov.nasa.worldwind.render.SurfaceConcaveShape
SurfaceConcaveShape.ImmediateModeCallback
 
Nested classes/interfaces inherited from class gov.nasa.worldwind.render.AbstractSurfaceShape
AbstractSurfaceShape.CachedLocations, AbstractSurfaceShape.CachedSectors, AbstractSurfaceShape.CacheEntry<T>
 
Field Summary
protected  LatLon center
           
protected static int ELLIPSE_DEFAULT_NUM_INTERVALS
           
protected static int ELLIPSE_MIN_NUM_INTERVALS
           
protected  Angle heading
           
protected  double majorRadius
           
protected  double minorRadius
           
 
Fields inherited from class gov.nasa.worldwind.render.SurfaceConcaveShape
glu, tess, texture
 
Fields inherited from class gov.nasa.worldwind.render.AbstractSurfaceShape
areaMeasurer, areaMeasurerLastModifiedTime, attributes, DEFAULT_CACHE_CAPACITY, DEFAULT_MAX_EDGE_INTERVALS, DEFAULT_MIN_EDGE_INTERVALS, DEFAULT_PATH_TYPE, DEFAULT_TEXELS_PER_EDGE_INTERVAL, drawLocations, locationCache, maxEdgeIntervals, minEdgeIntervals, pathType, renderer, sectorCache, showBoundingSectors, texelsPerEdgeInterval
 
Fields inherited from class gov.nasa.worldwind.render.AbstractSurfaceObject
lastModifiedTime, visible
 
Fields inherited from class gov.nasa.worldwind.avlist.AVListImpl
changeSupport
 
Constructor Summary
SurfaceEllipse()
           
SurfaceEllipse(LatLon center, double majorRadius, double minorRadius, Angle heading)
           
SurfaceEllipse(LatLon center, double majorRadius, double minorRadius, Angle heading, int intervals)
           
SurfaceEllipse(ShapeAttributes attributes)
           
SurfaceEllipse(ShapeAttributes attributes, int intervals)
           
SurfaceEllipse(ShapeAttributes attributes, LatLon center, double majorRadius, double minorRadius, Angle heading)
           
SurfaceEllipse(ShapeAttributes attributes, LatLon center, double majorRadius, double minorRadius, Angle heading, int intervals)
           
 
Method Summary
protected  java.lang.Iterable<? extends Sector> computeBoundingSectors(Globe globe)
           
protected  LatLon computeLocationFor(Globe globe, Angle angle)
           
protected  java.lang.Iterable<LatLon> computeLocations(Globe globe, int intervals)
           
protected  int computeNumEdgeIntervals(Globe globe, double edgeIntervalsPerDegree)
           
protected  int computeNumIntervals(Globe globe, double edgeIntervalsPerDegree)
           
protected  void doGetRestorableState(RestorableSupport rs, RestorableSupport.StateObject context)
           
protected  java.lang.Iterable<? extends Sector> doGetSectors(DrawContext dc, double texelSizeRadians)
           
protected  void doMoveTo(Position oldReferencePosition, Position newReferencePosition)
           
protected  void doRestoreState(RestorableSupport rs, RestorableSupport.StateObject context)
           
 LatLon getCenter()
           
 Angle getHeading()
           
 int getIntervals()
           
 java.lang.Iterable<? extends LatLon> getLocations(Globe globe)
          Returns the shape's locations as they appear on the specified globe.
protected  java.lang.Iterable<? extends LatLon> getLocations(Globe globe, double edgeIntervalsPerDegree)
           
 double getMajorRadius()
           
 double getMinorRadius()
           
 Position getReferencePosition()
           
protected  void legacyRestoreState(RestorableSupport rs, RestorableSupport.StateObject context)
          Restores state values from previous versions of the SurfaceShape state XML.
 void setCenter(LatLon center)
           
 void setHeading(Angle heading)
           
 void setIntervals(int intervals)
           
 void setMajorRadius(double radius)
           
 void setMinorRadius(double radius)
           
 void setRadii(double majorRadius, double minorRadius)
           
 
Methods inherited from class gov.nasa.worldwind.render.SurfaceConcaveShape
beginTessellation, doRenderInteriorToRegion, doRenderOutlineToRegion, doTessellate, drawInterior, drawOutline, endTessellation, getGLU, getGLUTessellator, getTexture, tessellateInterior
 
Methods inherited from class gov.nasa.worldwind.render.AbstractSurfaceShape
assembleRenderState, beginRenderToRegion, computeEdgeIntervalsPerDegree, doRenderBoundingSectors, doRenderShape, doRenderToRegion, endRenderToRegion, getArea, getArea, getAttributes, getCachedLocations, getCachedLocations, getHeight, getLength, getMinAndMaxEdgeIntervals, getPathType, getPerimeter, getRenderer, getRestorableState, getSectors, getSurfaceShapeSupport, getTexelsPerEdgeInterval, getWidth, isShowBoundingSectors, move, moveTo, onShapeChanged, pathTypeFromString, preRender, render, restoreState, setAttributes, setMinAndMaxEdgeIntervals, setPathType, setShowBoundingSectors, setTexelsPerEdgeInterval, setupAreaMeasurer
 
Methods inherited from class gov.nasa.worldwind.render.AbstractSurfaceObject
getLastModifiedTime, isVisible, renderToRegion, setVisible, updateModifiedTime
 
Methods inherited from class gov.nasa.worldwind.avlist.AVListImpl
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getDoubleValue, getDoubleValue, getEntries, getIntegerValue, getIntegerValue, getLongValue, getLongValue, 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
 
Methods inherited from interface gov.nasa.worldwind.render.SurfaceObject
getLastModifiedTime, isVisible, renderToRegion, setVisible
 
Methods inherited from interface gov.nasa.worldwind.avlist.AVList
addPropertyChangeListener, addPropertyChangeListener, clearList, copy, firePropertyChange, firePropertyChange, getEntries, getStringValue, getValue, getValues, hasKey, removeKey, removePropertyChangeListener, removePropertyChangeListener, setValue, setValues
 

Field Detail

center

protected LatLon center

ELLIPSE_DEFAULT_NUM_INTERVALS

protected static final int ELLIPSE_DEFAULT_NUM_INTERVALS
See Also:
Constant Field Values

ELLIPSE_MIN_NUM_INTERVALS

protected static final int ELLIPSE_MIN_NUM_INTERVALS
See Also:
Constant Field Values

heading

protected Angle heading

majorRadius

protected double majorRadius

minorRadius

protected double minorRadius
Constructor Detail

SurfaceEllipse

public SurfaceEllipse()

SurfaceEllipse

public SurfaceEllipse(LatLon center,
                      double majorRadius,
                      double minorRadius,
                      Angle heading)

SurfaceEllipse

public SurfaceEllipse(LatLon center,
                      double majorRadius,
                      double minorRadius,
                      Angle heading,
                      int intervals)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes,
                      int intervals)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes,
                      LatLon center,
                      double majorRadius,
                      double minorRadius,
                      Angle heading)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes,
                      LatLon center,
                      double majorRadius,
                      double minorRadius,
                      Angle heading,
                      int intervals)
Method Detail

computeBoundingSectors

protected java.lang.Iterable<? extends Sector> computeBoundingSectors(Globe globe)

computeLocationFor

protected LatLon computeLocationFor(Globe globe,
                                    Angle angle)

computeLocations

protected java.lang.Iterable<LatLon> computeLocations(Globe globe,
                                                      int intervals)

computeNumEdgeIntervals

protected int computeNumEdgeIntervals(Globe globe,
                                      double edgeIntervalsPerDegree)

computeNumIntervals

protected int computeNumIntervals(Globe globe,
                                  double edgeIntervalsPerDegree)

doGetRestorableState

protected void doGetRestorableState(RestorableSupport rs,
                                    RestorableSupport.StateObject context)
Overrides:
doGetRestorableState in class AbstractSurfaceShape

doGetSectors

protected java.lang.Iterable<? extends Sector> doGetSectors(DrawContext dc,
                                                            double texelSizeRadians)
Overrides:
doGetSectors in class AbstractSurfaceShape

doMoveTo

protected void doMoveTo(Position oldReferencePosition,
                        Position newReferencePosition)
Specified by:
doMoveTo in class AbstractSurfaceShape

doRestoreState

protected void doRestoreState(RestorableSupport rs,
                              RestorableSupport.StateObject context)
Overrides:
doRestoreState in class AbstractSurfaceShape

getCenter

public LatLon getCenter()

getHeading

public Angle getHeading()

getIntervals

public int getIntervals()

getLocations

public java.lang.Iterable<? extends LatLon> getLocations(Globe globe)
Description copied from interface: SurfaceShape
Returns the shape's locations as they appear on the specified globe.

Parameters:
globe - the globe the shape is related to.
Returns:
the shapes locations on the globe.

getLocations

protected java.lang.Iterable<? extends LatLon> getLocations(Globe globe,
                                                            double edgeIntervalsPerDegree)
Specified by:
getLocations in class AbstractSurfaceShape

getMajorRadius

public double getMajorRadius()

getMinorRadius

public double getMinorRadius()

getReferencePosition

public Position getReferencePosition()
Specified by:
getReferencePosition in interface Movable
Specified by:
getReferencePosition in class AbstractSurfaceShape

legacyRestoreState

protected void legacyRestoreState(RestorableSupport rs,
                                  RestorableSupport.StateObject context)
Description copied from class: AbstractSurfaceShape
Restores state values from previous versions of the SurfaceShape state XML. These values are stored or named differently than the current implementation. Those values which have not changed are ignored here, and will restored in {# doRestoreState }.

Overrides:
legacyRestoreState in class AbstractSurfaceShape
Parameters:
rs - RestorableSupport object which contains the state value properties.
context - active context in the RestorableSupport to read state from.

setCenter

public void setCenter(LatLon center)

setHeading

public void setHeading(Angle heading)

setIntervals

public void setIntervals(int intervals)

setMajorRadius

public void setMajorRadius(double radius)

setMinorRadius

public void setMinorRadius(double radius)

setRadii

public void setRadii(double majorRadius,
                     double minorRadius)

NASA World Wind