Package org.onebusaway.geospatial.services

Examples of org.onebusaway.geospatial.services.UTMProjection.forward()


    return forward(latlon, zone);
  }

  public static ProjectedPoint forward(CoordinatePoint latlon, int zone) {
    UTMProjection projection = new UTMProjection(zone);
    XYPoint point = projection.forward(latlon);
    return new ProjectedPoint(latlon.getLat(), latlon.getLon(), point.getX(),
        point.getY(), zone);
  }

  public static ProjectedPoint ensureSrid(ProjectedPoint point, int srid) {
View Full Code Here


      PointAndIndex pindex = bestAssignment.get(i);
      if (pindex.distanceAlongShape > maxDistanceTraveled) {
        int index = projectedShapePoints.size() - 1;
        XYPoint point = projectedShapePoints.get(index);
        StopEntryImpl stop = stopTimes.get(i).getStop();
        XYPoint stopPoint = projection.forward(stop.getStopLocation());
        double d = stopPoint.getDistance(point);
        pindex = new PointAndIndex(point, index, d, maxDistanceTraveled);
      }
      stopTimePoints[i] = pindex;
    }
View Full Code Here

    ShapePointsLibrary spl = new ShapePointsLibrary();
    List<XYPoint> projectedShapePoints = spl.getProjectedShapePoints(
        shapePoints, projection);

    XYPoint stopPoint = projection.forward(new CoordinatePoint(
        47.664922340500475, -122.29066873484038));

    double[] distanceAlongShape = {0.0, 405.7, 814.0};
    List<PointAndIndex> assignments = spl.computePotentialAssignments(
        projectedShapePoints, distanceAlongShape, stopPoint, 0, 3);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.