OMSpline (OpenMap API)
Date: 2016-12-09

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## com.bbn.openmap.omGraphics
Class OMSpline

    java.lang.Object
      com.bbn.openmap.omGraphics.geom.BasicGeometry
          com.bbn.openmap.omGraphics.OMGraphicAdapter
              com.bbn.openmap.omGraphics.OMAbstractLine
                  com.bbn.openmap.omGraphics.OMPoly
                      com.bbn.openmap.omGraphics.OMSpline

All Implemented Interfaces:
  OMGeometry, OMGraphic, OMGraphicConstants, java.io.Serializable, java.lang.Cloneable

Direct Known Subclasses:
  LabeledOMSpline, OMDecoratedSpline

    public class OMSpline

extends OMPoly

A splined OMPoly. With RENDERTYPE_LATLON mode, spline is computed on geographic locations, and then projected. Very few changes from OMPoly source code, just needed to calculate the spline before projecting in generate(). Look for HACK in source code ...

Version:
  15 juil. 2002
Author:
  Eric LEPICIER
See Also:
  Serialized Form

Field Summary

Fields inherited from class com.bbn.openmap.omGraphics.OMPoly
`coordMode, COORDMODE_ORIGIN, COORDMODE_PREVIOUS, doShapes, geometryClosed, isPolygon, lat, lon, rawllpts, units, xs, ys`

Fields inherited from class com.bbn.openmap.omGraphics.OMAbstractLine
`arrowhead, nsegs, xpoints, ypoints`

Fields inherited from class com.bbn.openmap.omGraphics.OMGraphicAdapter
`declutterType, displayPaint, edgeMatchesFill, fillPaint, hasLabel, linePaint, matted, mattingPaint, renderType, selected, selectPaint, showEditablePalette, stroke, textureMask`

Fields inherited from class com.bbn.openmap.omGraphics.geom.BasicGeometry
`attributes, lineType, needToRegenerate, shape, visible`

Fields inherited from interface com.bbn.openmap.omGraphics.OMGraphicConstants
`ADD_GRAPHIC_MASK, APP_OBJECT, BASIC_STROKE, CHANGE_APPEARANCE, clear, DECIMAL_DEGREES, DECLUTTERTYPE_LINE, DECLUTTERTYPE_MOVE, DECLUTTERTYPE_NONE, DECLUTTERTYPE_SPACE, DEFAULT_ROTATIONANGLE, DELETE_GRAPHIC_MASK, DESELECT_GRAPHIC_MASK, DESELECTALL_GRAPHIC_MASK, GRAPHICTYPE_ARC, GRAPHICTYPE_BITMAP, GRAPHICTYPE_CIRCLE, GRAPHICTYPE_ELLIPSE, GRAPHICTYPE_GRAPHIC, GRAPHICTYPE_GRID, GRAPHICTYPE_LINE, GRAPHICTYPE_POINT, GRAPHICTYPE_POLY, GRAPHICTYPE_RASTER, GRAPHICTYPE_RECTANGLE, GRAPHICTYPE_TEXT, INDEX, INFOLINE, LABEL, LINETYPE_GREATCIRCLE, LINETYPE_RHUMB, LINETYPE_STRAIGHT, LINETYPE_UNKNOWN, LOWER_GRAPHIC_MASK, LOWER_TO_BOTTOM_GRAPHIC_MASK, NO_ROTATE, OMGRAPHIC_ELT, OMGRAPHIC_TYPE_ATTR, RADIANS, RAISE_GRAPHIC_MASK, RAISE_TO_TOP_GRAPHIC_MASK, REMOVABLE, RENDERTYPE_LATLON, RENDERTYPE_OFFSET, RENDERTYPE_UNKNOWN, RENDERTYPE_XY, SELECT_GRAPHIC_MASK, SORT_GRAPHICS_MASK, TOOLTIP, UPDATE_GRAPHIC_MASK, UPDATED`

Constructor Summary
`OMSpline()` Default constructor.
`OMSpline(double[] llPoints, int units, int lType)` Create an OMSpline from a list of float lat/lon pairs.
`OMSpline(double[] llPoints, int units, int lType, int nsegs)` Create an OMSpline from a list of float lat/lon pairs.
`OMSpline(double latPoint, double lonPoint, int[] xypoints, int cMode)` Create an x/y OMSpline at an offset from lat/lon.
`OMSpline(double latPoint, double lonPoint, int[] xPoints, int[] yPoints, int cMode)` Create an x/y OMSpline at an offset from lat/lon.
`OMSpline(int[] xypoints)` Create an OMSpline from a list of xy pairs.
`OMSpline(int[] xPoints, int[] yPoints)` Create an x/y OMSpline.

Method Summary
`boolean` | `generate(Projection proj)` Prepare the spline for rendering.

Methods inherited from class com.bbn.openmap.omGraphics.OMPoly
`checkPoints, createShape, distance, getCoordMode, getDoShapes, getIndexOfFirstNodeOfSegIntersect, getLat, getLatLonArray, getLatLonArrayCopy, getLon, getNumSegs, getRawllpts, getShape, getUnits, getXs, getYs, insertRadians, isGeometryClosed, isPolygon, main, render, restore, setCoordMode, setDoShapes, setFillPaint, setIsPolygon, setLat, setLocation, setLocation, setLocation, setLocation, setLocation, setLon, setNumSegs, setXs, setYs, shouldRenderFill`

Methods inherited from class com.bbn.openmap.omGraphics.OMAbstractLine
`addArrowHead, addArrowHead, addArrowHead, addArrowHead, createArrowHeads, getArrowDirectionType, getArrowHead, getArrowLocation, getWingLength, getWingTip, hasArrowHead, restore, setArrowHead`

Methods inherited from class com.bbn.openmap.omGraphics.OMGraphicAdapter
`clone, deselect, getDeclutterType, getDisplayColor, getDisplayPaint, getEdgeMatchesFill, getFillColor, getFillPaint, getHasLabel, getLineColor, getLinePaint, getMattingPaint, getRenderType, getSelectColor, getSelectPaint, getShowEditablePalette, getStroke, getTextureMask, hasLineTypeChoice, initLabelingDuringGenerate, isClear, isMatted, isSelected, normalizeDistanceForLineWidth, readStroke, readTextureMask, regenerate, renderLabel, renderShape, select, setDeclutterType, setEdgeMatchesFill, setFillColor, setGraphicsColor, setGraphicsForEdge, setGraphicsForFill, setHasLabel, setLabelLocation, setLabelLocation, setLabelLocation, setLabelLocation, setLabelLocation, setLabelLocation, setLabelLocation, setLabelLocation, setLineColor, setLinePaint, setMatted, setMattingPaint, setRenderType, setSelectColor, setSelected, setSelectPaint, setShowEditablePalette, setStroke, setTextureMask, shouldRenderEdge, writeStroke, writeTextureMask`

Methods inherited from class com.bbn.openmap.omGraphics.geom.BasicGeometry
`_distance, appendShapeEdge, appendShapeEdge, appendShapeEdge, appendShapeEdge, clearAttributes, contains, createAttributeMap, createBoxShape, createShape, createShape, describeShapeDetail, describeShapeDetail, distanceToEdge, distanceToEdge, draw, draw, fill, fill, getAppObject, getAttribute, getAttributes, getDescription, getLineType, getNeedToRegenerate, isRenderable, isRenderable, isVisible, putAttribute, removeAttribute, setAppObject, setAttributes, setLineType, setNeedToRegenerate, setShape, setVisible`

Methods inherited from class java.lang.Object
`equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Methods inherited from interface com.bbn.openmap.omGraphics.OMGraphic
`clone, deselect, getDeclutterType, getDisplayColor, getDisplayPaint, getFillColor, getFillPaint, getLineColor, getLinePaint, getMattingPaint, getRenderType, getSelectColor, getSelectPaint, getShowEditablePalette, getStroke, getTextureMask, hasLineTypeChoice, isMatted, isSelected, normalizeDistanceForLineWidth, regenerate, renderLabel, select, setDeclutterType, setGraphicsColor, setGraphicsForEdge, setGraphicsForFill, setLabelLocation, setLabelLocation, setLabelLocation, setLinePaint, setMatted, setMattingPaint, setRenderType, setSelected, setSelectPaint, setShowEditablePalette, setStroke, setTextureMask, shouldRenderEdge`

Methods inherited from interface com.bbn.openmap.omGraphics.OMGeometry
`clearAttributes, contains, distanceToEdge, draw, draw, fill, fill, getAppObject, getAttribute, getAttributes, getDescription, getLineType, getNeedToRegenerate, isRenderable, isRenderable, isVisible, putAttribute, removeAttribute, setAppObject, setAttributes, setLineType, setNeedToRegenerate, setShape, setVisible`

Constructor Detail

### OMSpline

    public OMSpline()

  Default constructor.

### OMSpline

    public OMSpline(double[] llPoints,
                    int units,
                    int lType)

  Create an OMSpline from a list of float lat/lon pairs.

  NOTES:

  - llPoints array is converted into radians IN PLACE for more efficient handling internally if it's not already in radians! For even better performance, you should send us an array already in radians format!
  - If you want the curve to be connected (as a potato), you need to ensure that the first and last coordinate pairs are the same.

  Parameters:
    `llPoints` - array of lat/lon points, arranged lat, lon, lat, lon, etc.
    `units` - radians or decimal degrees. Use OMGraphic.RADIANS or OMGraphic.DECIMAL_DEGREES
    `lType` - line type, from a list defined in OMGraphic.

### OMSpline

    public OMSpline(double[] llPoints,
                    int units,
                    int lType,
                    int nsegs)

  Create an OMSpline from a list of float lat/lon pairs.

  NOTES:

  - llPoints array is converted into radians IN PLACE for more efficient handling internally if it's not already in radians! For even better performance, you should send us an array already in radians format!
  - If you want the curve to be connected (as a potato), you need to ensure that the first and last coordinate pairs are the same.

  Parameters:
    `llPoints` - array of lat/lon points, arranged lat, lon, lat, lon, etc.
    `units` - radians or decimal degrees. Use OMGraphic.RADIANS or OMGraphic.DECIMAL_DEGREES
    `lType` - line type, from a list defined in OMGraphic.
    `nsegs` - number of segment points (only for LINETYPE_GREATCIRCLE or LINETYPE_RHUMB line types, and if < 1, this value is generated internally)

### OMSpline

    public OMSpline(int[] xypoints)

  Create an OMSpline from a list of xy pairs. If you want the curve to be connected, you need to ensure that the first and last coordinate pairs are the same.

  Parameters:
    `xypoints` - array of x/y points, arranged x, y, x, y, etc.

### OMSpline

    public OMSpline(int[] xPoints,
                    int[] yPoints)

  Create an x/y OMSpline. If you want the curve to be connected, you need to ensure that the first and last coordinate pairs are the same.

  Parameters:
    `xPoints` - int[] of x coordinates
    `yPoints` - int[] of y coordinates

### OMSpline

    public OMSpline(double latPoint,
                    double lonPoint,
                    int[] xypoints,
                    int cMode)

  Create an x/y OMSpline at an offset from lat/lon. If you want the curve to be connected, you need to ensure that the first and last coordinate pairs are the same.

  Parameters:
    `latPoint` - latitude in decimal degrees
    `lonPoint` - longitude in decimal degrees
    `xypoints` - int[] of x,y pairs
    `cMode` - offset coordinate mode

### OMSpline

    public OMSpline(double latPoint,
                    double lonPoint,
                    int[] xPoints,
                    int[] yPoints,
                    int cMode)

  Create an x/y OMSpline at an offset from lat/lon. If you want the curve to be connected, you need to ensure that the first and last coordinate pairs are the same.

  Parameters:
    `latPoint` - latitude in decimal degrees
    `lonPoint` - longitude in decimal degrees
    `xPoints` - int[] of x coordinates
    `yPoints` - int[] of y coordinates
    `cMode` - offset coordinate mode

Method Detail

### generate

    public boolean generate(Projection proj)

  Prepare the spline for rendering.

  Specified by:
    `generate` in interface `OMGeometry`
  Overrides:
    `generate` in class `OMPoly`
  Parameters:
    `proj` - Projection
  Returns:
    true if generate was successful
  See Also:
    `OMGeometry.generate(Projection)`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details