1 | /* |
2 | * Copyright 2018 Uber Technologies, Inc. |
3 | * |
4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
5 | * you may not use this file except in compliance with the License. |
6 | * You may obtain a copy of the License at |
7 | * |
8 | * http://www.apache.org/licenses/LICENSE-2.0 |
9 | * |
10 | * Unless required by applicable law or agreed to in writing, software |
11 | * distributed under the License is distributed on an "AS IS" BASIS, |
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
13 | * See the License for the specific language governing permissions and |
14 | * limitations under the License. |
15 | */ |
16 | /** @file vec3d.h |
17 | * @brief 3D floating point vector functions. |
18 | */ |
19 | |
20 | #ifndef VEC3D_H |
21 | #define VEC3D_H |
22 | |
23 | #include "geoCoord.h" |
24 | |
25 | /** @struct Vec3D |
26 | * @brief 3D floating point structure |
27 | */ |
28 | typedef struct { |
29 | double x; ///< x component |
30 | double y; ///< y component |
31 | double z; ///< z component |
32 | } Vec3d; |
33 | |
34 | void _geoToVec3d(const GeoCoord* geo, Vec3d* point); |
35 | double _pointSquareDist(const Vec3d* p1, const Vec3d* p2); |
36 | |
37 | #endif |
38 | |