1 /* Copyright 2013-2019 CS Systèmes d'Information
2 * Licensed to CS Systèmes d'Information (CS) under one or more
3 * contributor license agreements. See the NOTICE file distributed with
4 * this work for additional information regarding copyright ownership.
5 * CS licenses this file to You under the Apache License, Version 2.0
6 * (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17 package org.orekit.rugged.intersection;
18
19 import org.hipparchus.geometry.euclidean.threed.Vector3D;
20 import org.orekit.bodies.GeodeticPoint;
21 import org.orekit.rugged.utils.ExtendedEllipsoid;
22 import org.orekit.rugged.utils.NormalizedGeodeticPoint;
23
24 /** Interface for Digital Elevation Model intersection algorithm.
25 * @author Luc Maisonobe
26 */
27 public interface IntersectionAlgorithm {
28
29 /** Compute intersection of line with Digital Elevation Model.
30 * @param ellipsoid reference ellipsoid
31 * @param position pixel position in ellipsoid frame
32 * @param los pixel line-of-sight in ellipsoid frame
33 * @return point at which the line first enters ground
34 */
35 NormalizedGeodeticPoint intersection(ExtendedEllipsoid ellipsoid, Vector3D position, Vector3D los);
36
37 /** Refine intersection of line with Digital Elevation Model.
38 * <p>
39 * This method is used to refine an intersection when a close guess is
40 * already known. The intersection is typically looked for by a direct
41 * {@link org.orekit.rugged.raster.Tile#cellIntersection(GeodeticPoint,
42 * Vector3D, int, int) cell intersection} in the tile which already
43 * contains the close guess, or any similar very fast algorithm.
44 * </p>
45 * @param ellipsoid reference ellipsoid
46 * @param position pixel position in ellipsoid frame
47 * @param los pixel line-of-sight in ellipsoid frame
48 * @param closeGuess guess close to the real intersection
49 * @return point at which the line first enters ground
50 */
51 NormalizedGeodeticPoint refineIntersection(ExtendedEllipsoid ellipsoid, Vector3D position, Vector3D los,
52 NormalizedGeodeticPoint closeGuess);
53
54 /** Get elevation at a given ground point.
55 * @param latitude ground point latitude
56 * @param longitude ground point longitude
57 * @return elevation at specified point
58 */
59 double getElevation(double latitude, double longitude);
60
61 }