-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
23 lines (18 loc) · 749 Bytes
/
Copy pathmain.cpp
File metadata and controls
23 lines (18 loc) · 749 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#include "beamsearch.h"
using namespace libhgp;
int main(int argc, char* argv[])
{
Vector3d n;
PL().HGP_Vector_Base_C(Vector3d(1, 0, 0), n);
std::cerr << "Vector base of (1,0,0): " << n[0] << " " << n[1] << " " << n[2] << std::endl;
// PPGL functions
auto b = PL().HGP_2D_Distance_Point_Point_C(Vector2d(0, 0), Vector2d(1, 1));
std::cerr << "Distance from point (0,0) to point (1,1): " << b << std::endl;
// PPGL functions
auto p = PL().HGP_3D_Projection_Point_Segment_C(Vector3d(0, 0, 0), Vector3d(17, 2, 2), Vector3d{ 32,23,234 });
std::cerr << "Project point (0,0,0) to segment (17,2,2)-(32,23,234): " << p[0] << " " << p[1] << " " << p[2] << std::endl;
Beamsearch a;
a.work();
system("pause");
return 0;
}