use of org.orekit.models.earth.tessellation.TileAiming in project Orekit by CS-SI.
the class DOPComputation method sample.
/**
* Mesh an area of interest into a grid of geodetic points.
*
* @param zone the area to mesh
* @param meshSize the size of the square meshes as a distance on the Earth surface (in meters)
* @return a list of geodetic points sampling the zone of interest
* @throws OrekitException if the area cannot be meshed
*/
private List<List<GeodeticPoint>> sample(final OneAxisEllipsoid shape, final List<GeodeticPoint> zone, final double meshSize) throws OrekitException {
// Convert the area into a SphericalPolygonsSet
final SphericalPolygonsSet sps = computeSphericalPolygonsSet(zone);
// Build the tesselator
final TileAiming aiming = new ConstantAzimuthAiming(shape, 0.);
final EllipsoidTessellator tessellator = new EllipsoidTessellator(shape, aiming, 4);
// Returns the sampled area as a grid of geodetic points
return tessellator.sample(sps, meshSize, meshSize);
}
Aggregations