ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
IntersectionTest.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #pragma once
9 
10 #include <Eigen/Dense>
11 
12 #include "CVCoreLib.h"
13 
14 namespace cloudViewer {
15 namespace utility {
16 
18 public:
19  static bool AABBAABB(const Eigen::Vector3d& min0,
20  const Eigen::Vector3d& max0,
21  const Eigen::Vector3d& min1,
22  const Eigen::Vector3d& max1);
23 
24  static bool TriangleTriangle3d(const Eigen::Vector3d& p0,
25  const Eigen::Vector3d& p1,
26  const Eigen::Vector3d& p2,
27  const Eigen::Vector3d& q0,
28  const Eigen::Vector3d& q1,
29  const Eigen::Vector3d& q2);
30 
31  static bool TriangleAABB(const Eigen::Vector3d& box_center,
32  const Eigen::Vector3d& box_half_size,
33  const Eigen::Vector3d& vert0,
34  const Eigen::Vector3d& vert1,
35  const Eigen::Vector3d& vert2);
36 
38  static bool PointsCoplanar(const Eigen::Vector3d& p0,
39  const Eigen::Vector3d& p1,
40  const Eigen::Vector3d& p2,
41  const Eigen::Vector3d& p3);
42 
49  static double LinesMinimumDistance(const Eigen::Vector3d& p0,
50  const Eigen::Vector3d& p1,
51  const Eigen::Vector3d& q0,
52  const Eigen::Vector3d& q1);
53 
59  static double LineSegmentsMinimumDistance(const Eigen::Vector3d& p0,
60  const Eigen::Vector3d& p1,
61  const Eigen::Vector3d& q0,
62  const Eigen::Vector3d& q1);
63 };
64 
65 } // namespace utility
66 } // namespace cloudViewer
#define CV_CORE_LIB_API
Definition: CVCoreLibWin.h:15
Generic file read and write utility for python interface.