Package gov.nasa.worldwind.render
Class Quadrilateral
- java.lang.Object
-
- gov.nasa.worldwind.render.Quadrilateral
-
- All Implemented Interfaces:
Draggable,Movable,Renderable
public class Quadrilateral extends java.lang.Object implements Renderable, Movable, Draggable
-
-
Field Summary
Fields Modifier and Type Field Description protected booleandragEnabledprotected DraggableSupportdraggableSupportprotected WWTexturetextureprotected java.nio.DoubleBuffertextureCoordinates
-
Constructor Summary
Constructors Constructor Description Quadrilateral(LatLon southwestCorner, LatLon northeastCorner, double elevation)Quadrilateral(Sector sector, double elevation)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoDrag(DragContext dragContext)voiddrag(DragContext dragContext)Drag the object given the providedDragContext.intgetAntiAliasHint()java.awt.ColorgetColor()LatLon[]getCorners()doublegetElevation()java.lang.ObjectgetImageSource()PositiongetReferencePosition()A position associated with the object that indicates its aggregate geographic position.protected voidinitializeTextureCoordinates()booleanisDragEnabled()Indicates whether the object is enabled for dragging.voidmove(Position delta)Shift the shape over the globe's surface while maintaining its original azimuth, its orientation relative to North.voidmoveTo(Position position)Move the shape over the globe's surface while maintaining its original azimuth, its orientation relative to North.voidrender(DrawContext dc)Causes thisRenderableto render itself using the provided draw context.voidsetAntiAliasHint(int hint)voidsetColor(java.awt.Color color)voidsetCorners(LatLon southWest, LatLon northEast)voidsetDragEnabled(boolean enabled)Controls whether the object is enabled for dragging.voidsetElevation(double elevation)voidsetImageSource(java.lang.Object imageSource)
-
-
-
Field Detail
-
texture
protected WWTexture texture
-
textureCoordinates
protected java.nio.DoubleBuffer textureCoordinates
-
dragEnabled
protected boolean dragEnabled
-
draggableSupport
protected DraggableSupport draggableSupport
-
-
Method Detail
-
getColor
public java.awt.Color getColor()
-
setColor
public void setColor(java.awt.Color color)
-
setImageSource
public void setImageSource(java.lang.Object imageSource)
-
getImageSource
public java.lang.Object getImageSource()
-
getAntiAliasHint
public int getAntiAliasHint()
-
setAntiAliasHint
public void setAntiAliasHint(int hint)
-
getCorners
public LatLon[] getCorners()
-
getElevation
public double getElevation()
-
setElevation
public void setElevation(double elevation)
-
initializeTextureCoordinates
protected void initializeTextureCoordinates()
-
render
public void render(DrawContext dc)
Description copied from interface:RenderableCauses thisRenderableto render itself using the provided draw context.- Specified by:
renderin interfaceRenderable- Parameters:
dc- theDrawContextto be used- See Also:
DrawContext
-
getReferencePosition
public Position getReferencePosition()
Description copied from interface:MovableA position associated with the object that indicates its aggregate geographic position. The chosen position varies among implementers of this interface. For objects defined by a list of positions, the reference position is typically the first position in the list. For symmetric objects the reference position is often the center of the object. In many cases the object's reference position may be explicitly specified by the application.- Specified by:
getReferencePositionin interfaceMovable- Returns:
- the object's reference position, or null if no reference position is available.
-
move
public void move(Position delta)
Description copied from interface:MovableShift the shape over the globe's surface while maintaining its original azimuth, its orientation relative to North.
-
moveTo
public void moveTo(Position position)
Description copied from interface:MovableMove the shape over the globe's surface while maintaining its original azimuth, its orientation relative to North.
-
isDragEnabled
public boolean isDragEnabled()
Description copied from interface:DraggableIndicates whether the object is enabled for dragging.- Specified by:
isDragEnabledin interfaceDraggable- Returns:
- true if the object is enabled, else false.
-
setDragEnabled
public void setDragEnabled(boolean enabled)
Description copied from interface:DraggableControls whether the object is enabled for dragging.- Specified by:
setDragEnabledin interfaceDraggable- Parameters:
enabled-trueif the object is enabled, elsefalse.
-
drag
public void drag(DragContext dragContext)
Description copied from interface:DraggableDrag the object given the providedDragContext.- Specified by:
dragin interfaceDraggable- Parameters:
dragContext- theDragContextof this dragging event.
-
doDrag
protected void doDrag(DragContext dragContext)
-
-