NASA World Wind

gov.nasa.worldwind.render
Class SurfaceEllipse

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

public class SurfaceEllipse
extends SurfaceConvexShape


Field Summary
protected  LatLon center
           
protected static int DEFAULT_NUM_INTERVALS
           
protected  Angle heading
           
protected static int MIN_NUM_INTERVALS
           
protected  double semiMajorAxisLength
           
protected  double semiMinorAxisLength
           
 
Fields inherited from class gov.nasa.worldwind.render.AbstractSurfaceShape
areaMeasurer, areaMeasurerLastModifiedTime, drawLocations, drawLocationsLastModifiedTime, edgeIntervalsPerDegree, pathType, renderer
 
Fields inherited from class gov.nasa.worldwind.render.AbstractSurfaceObject
lastModifiedTime, visible
 
Constructor Summary
SurfaceEllipse()
           
SurfaceEllipse(LatLon center, double semiMajorAxisLength, double semiMinorAxisLength, Angle heading)
           
SurfaceEllipse(LatLon center, double semiMajorAxisLength, double semiMinorAxisLength, Angle heading, int intervals)
           
SurfaceEllipse(ShapeAttributes attributes)
           
SurfaceEllipse(ShapeAttributes attributes, int intervals)
           
SurfaceEllipse(ShapeAttributes attributes, LatLon center, double semiMajorAxisLength, double semiMinorAxisLength, Angle heading)
           
SurfaceEllipse(ShapeAttributes attributes, LatLon center, double semiMajorAxisLength, double semiMinorAxisLength, Angle heading, int intervals)
           
 
Method Summary
protected  void computeLocations(Globe globe, int intervals, List<LatLon> locations)
           
protected  void computeLocations(Globe globe, List<LatLon> locations)
           
protected  void doGetRestorableState(RestorableSupport rs, RestorableSupport.StateObject context)
           
protected  void doMoveTo(Position oldReferencePosition, Position newReferencePosition)
           
protected  void doRestoreState(RestorableSupport rs, RestorableSupport.StateObject context)
           
 LatLon getCenter()
           
 Angle getHeading()
           
 int getIntervals()
           
 Position getReferencePosition()
           
 double getSemiMajorAxisLength()
           
 double getSemiMinorAxisLength()
           
protected  void legacyRestoreState(RestorableSupport rs, RestorableSupport.StateObject context)
          Restores state values from previous versions of the SurfaceShape state XML.
 void setAxisLengths(double semiMajorAxisLength, double semiMinorAxisLength)
           
 void setCenter(LatLon center)
           
 void setHeading(Angle heading)
           
 void setIntervals(int intervals)
           
 void setSemiMajorAxisLength(double length)
           
 void setSemiMinorAxisLength(double length)
           
 
Methods inherited from class gov.nasa.worldwind.render.SurfaceConvexShape
doRenderToRegion
 
Methods inherited from class gov.nasa.worldwind.render.AbstractSurfaceShape
getArea, getArea, getAttributes, getDrawLocations, getEdgeIntervalsPerDegree, getHeight, getLength, getLocations, getPathType, getPerimeter, getRenderer, getRestorableState, getSectors, getSurfaceShapeSupport, getWidth, move, moveTo, onShapeChanged, pathTypeFromString, preRender, render, restoreState, setAttributes, setEdgeIntervalsPerDegree, setPathType, setupAreaMeasurer
 
Methods inherited from class gov.nasa.worldwind.render.AbstractSurfaceObject
getLastModifiedTime, isVisible, renderToRegion, setVisible, updateModifiedTime
 
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
 

Field Detail

center

protected LatLon center

DEFAULT_NUM_INTERVALS

protected static final int DEFAULT_NUM_INTERVALS
See Also:
Constant Field Values

heading

protected Angle heading

MIN_NUM_INTERVALS

protected static final int MIN_NUM_INTERVALS
See Also:
Constant Field Values

semiMajorAxisLength

protected double semiMajorAxisLength

semiMinorAxisLength

protected double semiMinorAxisLength
Constructor Detail

SurfaceEllipse

public SurfaceEllipse()

SurfaceEllipse

public SurfaceEllipse(LatLon center,
                      double semiMajorAxisLength,
                      double semiMinorAxisLength,
                      Angle heading)

SurfaceEllipse

public SurfaceEllipse(LatLon center,
                      double semiMajorAxisLength,
                      double semiMinorAxisLength,
                      Angle heading,
                      int intervals)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes,
                      int intervals)

SurfaceEllipse

public SurfaceEllipse(ShapeAttributes attributes,
                      LatLon center,
                      double semiMajorAxisLength,
                      double semiMinorAxisLength,
                      Angle heading)

SurfaceEllipse

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

computeLocations

protected void computeLocations(Globe globe,
                                int intervals,
                                List<LatLon> locations)

computeLocations

protected void computeLocations(Globe globe,
                                List<LatLon> locations)
Specified by:
computeLocations in class AbstractSurfaceShape

doGetRestorableState

protected void doGetRestorableState(RestorableSupport rs,
                                    RestorableSupport.StateObject context)
Overrides:
doGetRestorableState 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()

getReferencePosition

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

getSemiMajorAxisLength

public double getSemiMajorAxisLength()

getSemiMinorAxisLength

public double getSemiMinorAxisLength()

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.

setAxisLengths

public void setAxisLengths(double semiMajorAxisLength,
                           double semiMinorAxisLength)

setCenter

public void setCenter(LatLon center)

setHeading

public void setHeading(Angle heading)

setIntervals

public void setIntervals(int intervals)

setSemiMajorAxisLength

public void setSemiMajorAxisLength(double length)

setSemiMinorAxisLength

public void setSemiMinorAxisLength(double length)

NASA World Wind