示例#1
0
 protected Iterable<? extends LatLon> computeDrawLocations(
     DrawContext dc, SurfaceTileDrawContext sdc) {
   ArrayList<LatLon> drawList = new ArrayList<LatLon>();
   double safeDistanceDegreesSquared = Math.pow(this.computeSafeRadius(dc, sdc).degrees, 2);
   for (LatLon location : this.getLocations()) {
     if (this.computeLocationDistanceDegreesSquared(sdc.getSector(), location)
         <= safeDistanceDegreesSquared) drawList.add(location);
   }
   return drawList;
 }
 @Override
 protected void applyModelviewTransform(DrawContext dc, SurfaceTileDrawContext sdc) {
   // Apply the geographic to surface tile coordinate transform.
   Matrix modelview = sdc.getModelviewMatrix();
   dc.getGL().glMultMatrixd(modelview.toArray(new double[16], 0, false), 0);
 }
示例#3
0
 protected Angle computeSafeRadius(DrawContext dc, SurfaceTileDrawContext sdc) {
   double regionPixelSize = this.computeDrawPixelSize(dc, sdc);
   Angle sectorRadius = this.computeSectorRadius(sdc.getSector());
   Angle iconRadius = this.computeIconRadius(dc, regionPixelSize, sdc.getSector());
   return sectorRadius.add(iconRadius);
 }