Class clsUtilityCPOF

java.lang.Object
armyc2.c5isr.RenderMultipoints.clsUtilityCPOF

public final class clsUtilityCPOF extends Object
CPOF utility functions taken from JavaLineArrayCPOF
  • Constructor Details

  • Method Details

    • GetFarPixels

      protected static void GetFarPixels(TGLight tg, IPointConversion converter, ArrayList farLeftPixels, ArrayList farRightPixels)
      Do a 360 degree horizontal shift for points on either side of the midpoint of the display, if the MBR for the pixels is greater than 180 degrees wide. Builds pixels for two symbols to draw a symbol flipped about the left edge and also a symbol flipped about the right edge. This function is typically used at world view. Caller must instantiate last two parameters.
      Parameters:
      tg -
      converter -
      farLeftPixels - - OUT - the resultant pixels for left shift symbol
      farRightPixels - - OUT - the result pixels for the right shift symbol
    • Change1TacticalAreas

      protected static boolean Change1TacticalAreas(TGLight tg, int lineType, IPointConversion converter, ArrayList<Shape2> shapes)
      Parameters:
      tg -
      lineType -
      converter -
      shapes -
      Returns:
    • GetCircularRangeFanFillTG

      protected static TGLight GetCircularRangeFanFillTG(TGLight tg)
      Create a tg with a new line type to used for circular range fan fill
      Parameters:
      tg -
      Returns:
    • ClearPixelsStyle

      protected static void ClearPixelsStyle(TGLight tg)
      after filtering pixels it needs to reinitialize the style to 0 or it causes CELineArraydotNet to build wrong shapes
      Parameters:
      tg -
    • FilterPoints2

      protected static void FilterPoints2(TGLight tg, IPointConversion converter)
      Filters too close points after segmenting and clipping
      Parameters:
      tg -
      converter -
    • canClipPoints

      public static Boolean canClipPoints(TGLight tg)
      returns true if the line type can be clipped before calculating the shapes
      Parameters:
      tg - tactical graphic
      Returns:
      true if can pre-clip points
    • LinesWithSeparateFill

      protected static boolean LinesWithSeparateFill(int linetype, ArrayList<Shape2> shapes)
      These get clipped so the fill must be treated as a separate shape. Normally lines with fill do not have a separate shape for the fill.
      Parameters:
      linetype -
      Returns:
    • Point2DtoPOINT2Mapped

      protected static ArrayList<POINT2> Point2DtoPOINT2Mapped(ArrayList<Point2D> pts2d, Map<String,Object> hashMap)
      uses a hash map to set the POINT2 style when creating tg.Pixels from Point2D ArrayList
      Parameters:
      pts2d -
      hashMap -
      Returns:
    • Point2DtoPOINT2

      protected static ArrayList<POINT2> Point2DtoPOINT2(ArrayList<Point2D> pts2d)
    • POINT2toPoint2D

      protected static ArrayList<Point2D> POINT2toPoint2D(ArrayList<POINT2> pts)
    • buildShapeSpecFromPoints

      protected static ArrayList<Shape2> buildShapeSpecFromPoints(TGLight tg0, Shape2 shapeSpec, ArrayList<POINT2> pts, Object clipArea)
      Clips a ShapeSpec. Assumes we are not post clipping splines, therefore all the operations are moveTo, lineTo. Each ShapeSpec is assumed to be: moveTo, lineTo ... lineTo, followed by another moveTo, lineTo, ... lineTo, followed by ...
      Parameters:
      shapeSpec -
      pts -
      clipArea -
      Returns:
      a single clipped shapeSpec
    • postClipShapes

      protected static ArrayList<Shape2> postClipShapes(TGLight tg, ArrayList<Shape2> shapeSpecsArray, Object clipArea)
      Currently assumes no MeTOC symbols are post clipped
      Parameters:
      tg -
      shapeSpecsArray -
      clipArea -
      Returns:
    • postSegmentFSA

      protected static void postSegmentFSA(TGLight tg, IPointConversion converter)
      cannot pre-segment the fire support areas, must post segment them after the pixels were calculated
      Parameters:
      tg -
      converter -
    • SegmentGeoPoints

      protected static void SegmentGeoPoints(TGLight tg, IPointConversion converter, double zoomFactor)
      Pre-segment the lines based on max or min latitude for the segment interval. This is necessary because GeoPixelconversion does not work well over distance greater than 1M meters, especially at extreme latitudes.
      Parameters:
      tg -
      converter -