Package gov.nasa.worldwind.symbology
Class TacticalGraphicLabel.OrderedLabel
- java.lang.Object
-
- gov.nasa.worldwind.symbology.TacticalGraphicLabel.OrderedLabel
-
- All Implemented Interfaces:
OrderedRenderable
,Renderable
- Enclosing class:
- TacticalGraphicLabel
protected class TacticalGraphicLabel.OrderedLabel extends java.lang.Object implements OrderedRenderable
-
-
Field Summary
Fields Modifier and Type Field Description protected double
eyeDistance
Distance from the eye point to the label's geographic location.protected Vec4
placePoint
Geographic position in cartesian coordinates.protected Angle
rotation
Rotation applied to the label.protected java.awt.Rectangle
screenExtent
Extent of the label on the screen.protected Vec4
screenPlacePoint
Location of the place point projected onto the screen.protected java.awt.Point
screenPoint
Location of the upper left corner of the text measured from the lower left corner of the viewport.
-
Constructor Summary
Constructors Modifier Constructor Description protected
OrderedLabel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doDrawOrderedRenderable(DrawContext dc, PickSupport pickCandidates)
protected void
doDrawText(TextRenderer textRenderer)
double
getDistanceFromEye()
Returns the ordered renderable's distance from the current view's eye point.protected java.awt.Font
getFont()
Layer
getPickLayer()
protected boolean
isDrawInterior()
boolean
isEnableBatchPicking()
boolean
isEnableBatchRendering()
void
pick(DrawContext dc, java.awt.Point pickPoint)
Executes a pick of the ordered renderable.void
render(DrawContext dc)
Causes thisRenderable
to render itself using the provided draw context.
-
-
-
Field Detail
-
placePoint
protected Vec4 placePoint
Geographic position in cartesian coordinates.
-
screenPlacePoint
protected Vec4 screenPlacePoint
Location of the place point projected onto the screen.
-
screenPoint
protected java.awt.Point screenPoint
Location of the upper left corner of the text measured from the lower left corner of the viewport. This point in OGL coordinates.
-
rotation
protected Angle rotation
Rotation applied to the label. This is computed each frame based on the orientation position.
-
screenExtent
protected java.awt.Rectangle screenExtent
Extent of the label on the screen.
-
eyeDistance
protected double eyeDistance
Distance from the eye point to the label's geographic location.
-
-
Method Detail
-
getDistanceFromEye
public double getDistanceFromEye()
Description copied from interface:OrderedRenderable
Returns the ordered renderable's distance from the current view's eye point. Intended to be used only to sort a list of ordered renderables according to eye distance, and only during frame generation when a view is active.- Specified by:
getDistanceFromEye
in interfaceOrderedRenderable
- Returns:
- the distance of the ordered renderable from the current view's eye point.
-
pick
public void pick(DrawContext dc, java.awt.Point pickPoint)
Description copied from interface:OrderedRenderable
Executes a pick of the ordered renderable.- Specified by:
pick
in interfaceOrderedRenderable
- Parameters:
dc
- the current draw context.pickPoint
- the pick point.
-
render
public void render(DrawContext dc)
Description copied from interface:Renderable
Causes thisRenderable
to render itself using the provided draw context.- Specified by:
render
in interfaceRenderable
- Parameters:
dc
- theDrawContext
to be used- See Also:
DrawContext
-
isEnableBatchRendering
public boolean isEnableBatchRendering()
-
isEnableBatchPicking
public boolean isEnableBatchPicking()
-
getPickLayer
public Layer getPickLayer()
-
doDrawOrderedRenderable
protected void doDrawOrderedRenderable(DrawContext dc, PickSupport pickCandidates)
-
getFont
protected java.awt.Font getFont()
-
isDrawInterior
protected boolean isDrawInterior()
-
doDrawText
protected void doDrawText(TextRenderer textRenderer)
-
-