public class SegmentPlaneRenderer
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
protected static class |
SegmentPlaneRenderer.ControlPointInfo |
protected static class |
SegmentPlaneRenderer.OrderedText |
protected static class |
SegmentPlaneRenderer.RenderInfo |
Modifier and Type | Field and Description |
---|---|
protected double |
maxObjectSizeCoefficient |
protected double |
minObjectSize |
protected PickSupport |
pickSupport |
protected java.util.Map<SegmentPlane,SegmentPlaneRenderer.RenderInfo> |
renderInfoMap |
Constructor and Description |
---|
SegmentPlaneRenderer() |
Modifier and Type | Method and Description |
---|---|
protected void |
begin(DrawContext dc,
OGLStackHandler ogsh) |
protected boolean |
bindGeometryAttributes(DrawContext dc,
SegmentPlane segmentPlane,
java.lang.Object key,
boolean disablePicking) |
protected boolean |
bindGeometryAttributesAsLine(DrawContext dc,
SegmentPlane segmentPlane,
java.lang.Object key,
boolean disablePicking) |
protected boolean |
bindLabelAttributes(DrawContext dc,
SegmentPlane segmentPlane,
java.lang.Object key) |
protected PickedObject |
bindPickableObject(DrawContext dc,
java.lang.Object userObject,
java.lang.Object objectId) |
protected void |
bindPlaneVertexGeometry(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected java.awt.Rectangle |
computeAverageLabelSize(SegmentPlaneRenderer.OrderedText[] text,
int textCount) |
Position |
computeControlPointPosition(SectorGeometryList sgl,
Globe globe,
SegmentPlane segmentPlane,
SegmentPlane.ControlPoint controlPoint) |
protected double |
computeMaxSizeForPixels(Globe globe,
SegmentPlane segmentPlane) |
protected double |
computeMinDistanceBetweenLabels(DrawContext dc,
SegmentPlaneRenderer.OrderedText[] text,
int textCount) |
protected Vec4 |
computeNearestGridLineToPoint(Vec4 point,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected Vec4 |
computeNearestLineToPoint(Vec4 point,
int count,
java.nio.IntBuffer indices,
java.nio.DoubleBuffer vertices,
Vec4 referenceCenter) |
protected Vec4 |
computeNearestOutlineToPoint(Vec4 point,
SegmentPlaneRenderer.RenderInfo renderInfo) |
double |
computeObjectSize(View view,
Globe globe,
SegmentPlane segmentPlane,
java.lang.Object key,
Vec4 point) |
protected double |
computeObjectSize(View view,
Globe globe,
SegmentPlane segmentPlane,
java.lang.Object key,
Vec4 point,
boolean usePickSize) |
protected static void |
computePlaneFillIndices(int uStacks,
int vStacks,
java.nio.IntBuffer buffer) |
protected static void |
computePlaneGridIndices(int uStacks,
int vStacks,
java.nio.IntBuffer buffer) |
protected void |
computePlaneNormals(Globe globe,
SegmentPlane segmentPlane,
int indexCount,
int vertexCount,
java.nio.IntBuffer indices,
java.nio.DoubleBuffer vertices,
java.nio.DoubleBuffer buffer) |
protected static void |
computePlaneOutlineIndices(int uStacks,
int vStacks,
int mask,
java.nio.IntBuffer buffer) |
protected void |
computePlaneParameterization(Globe globe,
SegmentPlane segmentPlane,
int[] gridCellCounts,
double[] gridCellParams) |
protected void |
computePlaneVertices(Globe globe,
SegmentPlane segmentPlane,
int uStacks,
int vStacks,
double uStep,
double vStep,
Vec4 referenceCenter,
java.nio.DoubleBuffer buffer) |
protected Position |
computePositionOnPlane(SectorGeometryList sgl,
Globe globe,
SegmentPlane segmentPlane,
double u,
double v,
boolean relativeToSurface) |
protected double |
computeSizeForPixels(View view,
Vec4 point,
double pixels,
double minSize,
double maxSize) |
protected double |
computeSurfaceElevation(SectorGeometryList sgl,
Globe globe,
Angle latitude,
Angle longitude) |
protected void |
createBorderGeometry(Globe globe,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
createControlPointGeometry(Globe globe,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected SegmentPlaneRenderer.OrderedText |
createLabel(DrawContext dc,
SegmentPlane segmentPlane,
Position position,
AVList values,
java.lang.Object key) |
protected void |
createSegmentPlaneGeometry(Globe globe,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
draw(DrawContext dc,
SegmentPlane segmentPlane,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawAxisLabels(DrawContext dc,
SegmentPlaneRenderer.OrderedText[] text,
int startPos,
int count,
double averageSize,
double minDistance) |
protected void |
drawAxisLabels(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawBorder(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo,
Matrix modelview,
double radius,
double height) |
protected void |
drawBorderCap(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
drawBorderCylinder(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
drawControlPoint(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlane.ControlPoint controlPoint,
Position position,
MarkerShape shape) |
protected void |
drawControlPointGeometry(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.ControlPointInfo controlPointInfo) |
protected void |
drawControlPointLabel(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlane.ControlPoint controlPoint,
Position position) |
protected void |
drawControlPoints(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawHorizontalAxisLabels(DrawContext dc,
SegmentPlane segmentPlane) |
protected void |
drawLabel(DrawContext dc,
SegmentPlane segmentPlane,
Position position,
AVList values,
java.lang.Object key) |
protected void |
drawPlaneBackground(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawPlaneBorder(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawPlaneFillElements(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
drawPlaneGeometry(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawPlaneGrid(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawPlaneGridElements(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
drawPlaneOutline(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawPlaneOutlineElements(DrawContext dc,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected void |
drawSegmentAltimeter(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawSegmentAltimeterGeometry(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawSegmentAltimeterLabel(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawSegmentPlane(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
drawVerticalAxisLabels(DrawContext dc,
SegmentPlane segmentPlane) |
protected void |
end(DrawContext dc,
OGLStackHandler ogsh) |
double |
getMaxObjectSizeCoefficient() |
double |
getMinObjectSize() |
protected static int |
getPlaneFillIndexCount(int uStacks,
int vStacks) |
protected static int |
getPlaneGridIndexCount(int uStacks,
int vStacks) |
protected static int |
getPlaneOutlineIndexCount(int uStacks,
int vStacks,
int mask) |
protected static int |
getPlaneVertexCount(int uStacks,
int vStacks) |
protected SegmentPlaneRenderer.RenderInfo |
getRenderInfoFor(Globe globe,
SegmentPlane segmentPlane) |
protected MultiLineTextRenderer |
getTextRendererFor(DrawContext dc,
java.awt.Font font) |
protected PickedObject |
getTopPickedObject(DrawContext dc,
java.awt.Point pickPoint,
java.lang.Object pickedObjectId) |
protected static Vec4 |
getVertex3(int position,
java.nio.DoubleBuffer vertices) |
Vec4 |
intersect(Globe globe,
Line ray,
SegmentPlane segmentPlane) |
protected Vec4 |
intersectRayWithFill(Line ray,
SegmentPlaneRenderer.RenderInfo renderInfo) |
protected Vec4 |
intersectRayWithTriangleStrip(Line ray,
int count,
java.nio.IntBuffer indices,
java.nio.DoubleBuffer vertices,
Vec4 referenceCenter) |
void |
pick(DrawContext dc,
SegmentPlane segmentPlane,
java.awt.Point pickPoint,
Layer layer) |
protected static void |
putVertex3(Vec4 vec,
int position,
java.nio.DoubleBuffer vertices) |
protected void |
registerPickedObject(DrawContext dc,
PickedObject pickedObject,
Layer layer) |
void |
render(DrawContext dc,
SegmentPlane segmentPlane) |
protected void |
resolveControlPointPick(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
resolvePlaneBackgroundPick(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
resolvePlaneGridPick(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
protected void |
resolvePlaneOutlinePick(DrawContext dc,
SegmentPlane segmentPlane,
SegmentPlaneRenderer.RenderInfo renderInfo,
java.awt.Point pickPoint,
Layer layer) |
void |
setMaxObjectSizeCoefficient(double coefficient) |
void |
setMinObjectSize(double size) |
protected double maxObjectSizeCoefficient
protected double minObjectSize
protected final PickSupport pickSupport
protected java.util.Map<SegmentPlane,SegmentPlaneRenderer.RenderInfo> renderInfoMap
protected void begin(DrawContext dc, OGLStackHandler ogsh)
protected boolean bindGeometryAttributes(DrawContext dc, SegmentPlane segmentPlane, java.lang.Object key, boolean disablePicking)
protected boolean bindGeometryAttributesAsLine(DrawContext dc, SegmentPlane segmentPlane, java.lang.Object key, boolean disablePicking)
protected boolean bindLabelAttributes(DrawContext dc, SegmentPlane segmentPlane, java.lang.Object key)
protected PickedObject bindPickableObject(DrawContext dc, java.lang.Object userObject, java.lang.Object objectId)
protected void bindPlaneVertexGeometry(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo)
protected java.awt.Rectangle computeAverageLabelSize(SegmentPlaneRenderer.OrderedText[] text, int textCount)
public Position computeControlPointPosition(SectorGeometryList sgl, Globe globe, SegmentPlane segmentPlane, SegmentPlane.ControlPoint controlPoint)
protected double computeMaxSizeForPixels(Globe globe, SegmentPlane segmentPlane)
protected double computeMinDistanceBetweenLabels(DrawContext dc, SegmentPlaneRenderer.OrderedText[] text, int textCount)
protected Vec4 computeNearestGridLineToPoint(Vec4 point, SegmentPlaneRenderer.RenderInfo renderInfo)
protected Vec4 computeNearestLineToPoint(Vec4 point, int count, java.nio.IntBuffer indices, java.nio.DoubleBuffer vertices, Vec4 referenceCenter)
protected Vec4 computeNearestOutlineToPoint(Vec4 point, SegmentPlaneRenderer.RenderInfo renderInfo)
public double computeObjectSize(View view, Globe globe, SegmentPlane segmentPlane, java.lang.Object key, Vec4 point)
protected double computeObjectSize(View view, Globe globe, SegmentPlane segmentPlane, java.lang.Object key, Vec4 point, boolean usePickSize)
protected static void computePlaneFillIndices(int uStacks, int vStacks, java.nio.IntBuffer buffer)
protected static void computePlaneGridIndices(int uStacks, int vStacks, java.nio.IntBuffer buffer)
protected void computePlaneNormals(Globe globe, SegmentPlane segmentPlane, int indexCount, int vertexCount, java.nio.IntBuffer indices, java.nio.DoubleBuffer vertices, java.nio.DoubleBuffer buffer)
protected static void computePlaneOutlineIndices(int uStacks, int vStacks, int mask, java.nio.IntBuffer buffer)
protected void computePlaneParameterization(Globe globe, SegmentPlane segmentPlane, int[] gridCellCounts, double[] gridCellParams)
protected void computePlaneVertices(Globe globe, SegmentPlane segmentPlane, int uStacks, int vStacks, double uStep, double vStep, Vec4 referenceCenter, java.nio.DoubleBuffer buffer)
protected Position computePositionOnPlane(SectorGeometryList sgl, Globe globe, SegmentPlane segmentPlane, double u, double v, boolean relativeToSurface)
protected double computeSizeForPixels(View view, Vec4 point, double pixels, double minSize, double maxSize)
protected double computeSurfaceElevation(SectorGeometryList sgl, Globe globe, Angle latitude, Angle longitude)
protected void createBorderGeometry(Globe globe, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void createControlPointGeometry(Globe globe, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo)
protected SegmentPlaneRenderer.OrderedText createLabel(DrawContext dc, SegmentPlane segmentPlane, Position position, AVList values, java.lang.Object key)
protected void createSegmentPlaneGeometry(Globe globe, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void draw(DrawContext dc, SegmentPlane segmentPlane, java.awt.Point pickPoint, Layer layer)
protected void drawAxisLabels(DrawContext dc, SegmentPlaneRenderer.OrderedText[] text, int startPos, int count, double averageSize, double minDistance)
protected void drawAxisLabels(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawBorder(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo, Matrix modelview, double radius, double height)
protected void drawBorderCap(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void drawBorderCylinder(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void drawControlPoint(DrawContext dc, SegmentPlane segmentPlane, SegmentPlane.ControlPoint controlPoint, Position position, MarkerShape shape)
protected void drawControlPointGeometry(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.ControlPointInfo controlPointInfo)
protected void drawControlPointLabel(DrawContext dc, SegmentPlane segmentPlane, SegmentPlane.ControlPoint controlPoint, Position position)
protected void drawControlPoints(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawHorizontalAxisLabels(DrawContext dc, SegmentPlane segmentPlane)
protected void drawLabel(DrawContext dc, SegmentPlane segmentPlane, Position position, AVList values, java.lang.Object key)
protected void drawPlaneBackground(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawPlaneBorder(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawPlaneFillElements(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void drawPlaneGeometry(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawPlaneGrid(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawPlaneGridElements(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void drawPlaneOutline(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawPlaneOutlineElements(DrawContext dc, SegmentPlaneRenderer.RenderInfo renderInfo)
protected void drawSegmentAltimeter(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawSegmentAltimeterGeometry(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawSegmentAltimeterLabel(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawSegmentPlane(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void drawVerticalAxisLabels(DrawContext dc, SegmentPlane segmentPlane)
protected void end(DrawContext dc, OGLStackHandler ogsh)
public double getMaxObjectSizeCoefficient()
public double getMinObjectSize()
protected static int getPlaneFillIndexCount(int uStacks, int vStacks)
protected static int getPlaneGridIndexCount(int uStacks, int vStacks)
protected static int getPlaneOutlineIndexCount(int uStacks, int vStacks, int mask)
protected static int getPlaneVertexCount(int uStacks, int vStacks)
protected SegmentPlaneRenderer.RenderInfo getRenderInfoFor(Globe globe, SegmentPlane segmentPlane)
protected MultiLineTextRenderer getTextRendererFor(DrawContext dc, java.awt.Font font)
protected PickedObject getTopPickedObject(DrawContext dc, java.awt.Point pickPoint, java.lang.Object pickedObjectId)
protected static Vec4 getVertex3(int position, java.nio.DoubleBuffer vertices)
public Vec4 intersect(Globe globe, Line ray, SegmentPlane segmentPlane)
protected Vec4 intersectRayWithFill(Line ray, SegmentPlaneRenderer.RenderInfo renderInfo)
protected Vec4 intersectRayWithTriangleStrip(Line ray, int count, java.nio.IntBuffer indices, java.nio.DoubleBuffer vertices, Vec4 referenceCenter)
public void pick(DrawContext dc, SegmentPlane segmentPlane, java.awt.Point pickPoint, Layer layer)
protected static void putVertex3(Vec4 vec, int position, java.nio.DoubleBuffer vertices)
protected void registerPickedObject(DrawContext dc, PickedObject pickedObject, Layer layer)
public void render(DrawContext dc, SegmentPlane segmentPlane)
protected void resolveControlPointPick(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void resolvePlaneBackgroundPick(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void resolvePlaneGridPick(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
protected void resolvePlaneOutlinePick(DrawContext dc, SegmentPlane segmentPlane, SegmentPlaneRenderer.RenderInfo renderInfo, java.awt.Point pickPoint, Layer layer)
public void setMaxObjectSizeCoefficient(double coefficient)
public void setMinObjectSize(double size)