MRPT  2.0.4
TPolygonWithPlane.cpp
Go to the documentation of this file.
1 /* +------------------------------------------------------------------------+
2  | Mobile Robot Programming Toolkit (MRPT) |
3  | https://www.mrpt.org/ |
4  | |
5  | Copyright (c) 2005-2020, Individual contributors, see AUTHORS file |
6  | See: https://www.mrpt.org/Authors - All rights reserved. |
7  | Released under BSD License. See: https://www.mrpt.org/License |
8  +------------------------------------------------------------------------+ */
9 
10 #include "math-precomp.h" // Precompiled headers
11 
12 #include <mrpt/math/CMatrixFixed.h>
14 #include <mrpt/math/geometry.h>
15 
16 using namespace mrpt::math;
17 using std::vector;
18 
20 {
23  // inversePose = -pose;
24  CMatrixDouble44 P_inv;
27 
29 }
31  const vector<TPolygon3D>& oldPolys, vector<TPolygonWithPlane>& newPolys)
32 {
33  size_t N = oldPolys.size();
34  newPolys.resize(N);
35  for (size_t i = 0; i < N; i++) newPolys[i] = oldPolys[i];
36 }
A compile-time fixed-size numeric matrix container.
Definition: CMatrixFixed.h:33
mrpt::math::TPose3D inversePose
Plane&#39;s inverse pose.
void fromHomogeneousMatrix(const mrpt::math::CMatrixDouble44 &HG)
Definition: TPose3D.cpp:201
void getAsPose3D(mrpt::math::TPose3D &outPose) const
Definition: TPlane.cpp:73
This base provides a set of functions for maths stuff.
void unsafeProjectPolygon(const TPolygon3D &poly, const TPose3D &pose, TPolygon2D &newPoly)
Definition: geometry.cpp:531
TPolygon3D poly
Actual polygon.
TPolygon2D poly2D
Polygon, after being projected to the plane using inversePose.
void getBestFittingPlane(TPlane &p) const
Gets the best fitting plane, disregarding whether the polygon actually fits inside or not...
Definition: TPolygon3D.cpp:77
TPolygonWithPlane()=default
Basic constructor.
mrpt::math::TPose3D pose
Plane&#39;s pose.
void getInverseHomogeneousMatrix(mrpt::math::CMatrixDouble44 &HG) const
Definition: TPose3D.cpp:228
static void getPlanes(const std::vector< TPolygon3D > &oldPolys, std::vector< TPolygonWithPlane > &newPolys)
Static method for vectors.
TPlane plane
Plane containing the polygon.
3D polygon, inheriting from std::vector<TPoint3D>
Definition: TPolygon3D.h:20



Page generated by Doxygen 1.8.14 for MRPT 2.0.4 Git: 33de1d0ad Sat Jun 20 11:02:42 2020 +0200 at sáb jun 20 17:35:17 CEST 2020