Point Cloud Library (PCL) 1.12.0
|
Functions | |
template<typename T > | |
bool | compareOrderedPairs (const std::pair< T, T > &a, const std::pair< T, T > &b) |
template<typename T > | |
T | sqr (T a) |
template<typename T > | |
T | clamp (T value, T min, T max) |
template<typename T > | |
void | expandBoundingBox (T dst[6], const T src[6]) |
Expands the destination bounding box 'dst' such that it contains 'src'. | |
template<typename T > | |
void | expandBoundingBoxToContainPoint (T bbox[6], const T p[3]) |
Expands the bounding box 'bbox' such that it contains the point 'p'. | |
template<typename T > | |
void | set3 (T v[3], T value) |
v[0] = v[1] = v[2] = value | |
template<typename T > | |
void | copy3 (const T src[3], T dst[3]) |
dst = src | |
template<typename T > | |
void | copy3 (const T src[3], pcl::PointXYZ &dst) |
dst = src | |
template<typename T > | |
void | flip3 (T a[3]) |
a = -a | |
template<typename T > | |
bool | equal3 (const T a[3], const T b[3]) |
a = b | |
template<typename T > | |
void | add3 (T a[3], const T b[3]) |
a += b | |
template<typename T > | |
void | sum3 (const T a[3], const T b[3], T c[3]) |
c = a + b | |
template<typename T > | |
void | diff3 (const T a[3], const T b[3], T c[3]) |
c = a - b | |
template<typename T > | |
void | cross3 (const T v1[3], const T v2[3], T out[3]) |
template<typename T > | |
T | length3 (const T v[3]) |
Returns the length of v. | |
template<typename T > | |
T | distance3 (const T a[3], const T b[3]) |
Returns the Euclidean distance between a and b. | |
template<typename T > | |
T | sqrDistance3 (const T a[3], const T b[3]) |
Returns the squared Euclidean distance between a and b. | |
template<typename T > | |
T | dot3 (const T a[3], const T b[3]) |
Returns the dot product a*b. | |
template<typename T > | |
T | dot3 (T x, T y, T z, T u, T v, T w) |
Returns the dot product (x, y, z)*(u, v, w) = x*u + y*v + z*w. | |
template<typename T > | |
void | mult3 (T *v, T scalar) |
v = scalar*v. | |
template<typename T > | |
void | mult3 (const T *v, T scalar, T *out) |
out = scalar*v. | |
template<typename T > | |
void | normalize3 (T v[3]) |
Normalize v. | |
template<typename T > | |
T | sqrLength3 (const T v[3]) |
Returns the square length of v. | |
template<typename T > | |
void | projectOnPlane3 (const T x[3], const T planeNormal[3], T out[3]) |
Projects 'x' on the plane through 0 and with normal 'planeNormal' and saves the result in 'out'. | |
template<typename T > | |
void | identity3x3 (T m[9]) |
Sets 'm' to the 3x3 identity matrix. | |
template<typename T > | |
void | mult3x3 (const T m[9], const T v[3], T out[3]) |
out = mat*v. | |
template<typename T > | |
void | mult3x3 (const T x[3], const T y[3], const T z[3], const T m[3][3], T out[9]) |
Let x, y, z be the columns of the matrix a = [x|y|z]. | |
template<class T > | |
void | transform (const T t[12], const T p[3], T out[3]) |
The first 9 elements of 't' are treated as a 3x3 matrix (row major order) and the last 3 as a translation. | |
template<class T > | |
void | transform (const T t[12], T x, T y, T z, T out[3]) |
The first 9 elements of 't' are treated as a 3x3 matrix (row major order) and the last 3 as a translation. | |
template<class T > | |
void | transform (const Eigen::Matrix< T, 4, 4 > &mat, const pcl::PointXYZ &p, pcl::PointXYZ &out) |
Compute out = (upper left 3x3 of mat)*p + last column of mat. | |
template<class T > | |
void | transform (const T t[12], const pcl::PointXYZ &p, T out[3]) |
The first 9 elements of 't' are treated as a 3x3 matrix (row major order) and the last 3 as a translation. | |
template<typename T > | |
bool | pointsAreCoplanar (const T p1[3], const T n1[3], const T p2[3], const T n2[3], T max_angle) |
Returns true if the points 'p1' and 'p2' are co-planar and false otherwise. | |
template<typename Scalar > | |
void | array12ToMatrix4x4 (const Scalar src[12], Eigen::Matrix< Scalar, 4, 4 > &dst) |
template<typename Scalar > | |
void | matrix4x4ToArray12 (const Eigen::Matrix< Scalar, 4, 4 > &src, Scalar dst[12]) |
template<typename T > | |
void | eigenMatrix3x3ToArray9RowMajor (const Eigen::Matrix< T, 3, 3 > &src, T dst[9]) |
The method copies the input array 'src' to the eigen matrix 'dst' in row major order. | |
template<typename T > | |
void | toEigenMatrix3x3RowMajor (const T src[9], Eigen::Matrix< T, 3, 3 > &dst) |
The method copies the input array 'src' to the eigen matrix 'dst' in row major order. | |
template<typename T > | |
void | axisAngleToRotationMatrix (const T axis_angle[3], T rotation_matrix[9]) |
brief Computes a rotation matrix from the provided input vector 'axis_angle'. | |
template<typename T > | |
void | rotationMatrixToAxisAngle (const T rotation_matrix[9], T axis[3], T &angle) |
brief Extracts the angle-axis representation from 'rotation_matrix', i.e., computes a rotation 'axis' and an 'angle' of rotation about that axis from the provided input. | |
a += b
Definition at line 150 of file auxiliary.h.
Referenced by pcl::recognition::RotationSpaceCell::Entry::addRigidTransform().
void pcl::recognition::aux::array12ToMatrix4x4 | ( | const Scalar | src[12], |
Eigen::Matrix< Scalar, 4, 4 > & | dst ) |
Definition at line 366 of file auxiliary.h.
void pcl::recognition::aux::axisAngleToRotationMatrix | ( | const T | axis_angle[3], |
T | rotation_matrix[9] ) |
brief Computes a rotation matrix from the provided input vector 'axis_angle'.
The direction of 'axis_angle' is the rotation axis and its magnitude is the angle of rotation about that axis. 'rotation_matrix' is the output rotation matrix saved in row major order.
Definition at line 411 of file auxiliary.h.
References eigenMatrix3x3ToArray9RowMajor(), identity3x3(), length3(), and mult3().
Referenced by pcl::recognition::RotationSpaceCell::Entry::computeAverageRigidTransform().
T pcl::recognition::aux::clamp | ( | T | value, |
T | min, | ||
T | max ) |
Definition at line 70 of file auxiliary.h.
Referenced by pointsAreCoplanar().
bool pcl::recognition::aux::compareOrderedPairs | ( | const std::pair< T, T > & | a, |
const std::pair< T, T > & | b ) |
Definition at line 55 of file auxiliary.h.
void pcl::recognition::aux::copy3 | ( | const T | src[3], |
pcl::PointXYZ & | dst ) |
dst = src
Definition at line 125 of file auxiliary.h.
dst = src
Definition at line 116 of file auxiliary.h.
Referenced by pcl::recognition::RotationSpaceCell::Entry::computeAverageRigidTransform(), pcl::recognition::RotationSpaceCell::Entry::Entry(), and pcl::recognition::RotationSpaceCell::Entry::operator=().
Definition at line 176 of file auxiliary.h.
c = a - b
Definition at line 168 of file auxiliary.h.
Returns the Euclidean distance between a and b.
Definition at line 192 of file auxiliary.h.
References length3().
Returns the dot product a*b.
Definition at line 207 of file auxiliary.h.
Referenced by pointsAreCoplanar(), and projectOnPlane3().
T pcl::recognition::aux::dot3 | ( | T | x, |
T | y, | ||
T | z, | ||
T | u, | ||
T | v, | ||
T | w ) |
Returns the dot product (x, y, z)*(u, v, w) = x*u + y*v + z*w.
Definition at line 214 of file auxiliary.h.
void pcl::recognition::aux::eigenMatrix3x3ToArray9RowMajor | ( | const Eigen::Matrix< T, 3, 3 > & | src, |
T | dst[9] ) |
The method copies the input array 'src' to the eigen matrix 'dst' in row major order.
dst[0] = src(0,0); dst[1] = src(0,1); dst[2] = src(0,2); dst[3] = src(1,0); dst[4] = src(1,1); dst[5] = src(1,2); dst[6] = src(2,0); dst[7] = src(2,1); dst[8] = src(2,2);
Definition at line 388 of file auxiliary.h.
Referenced by axisAngleToRotationMatrix().
a = b
Definition at line 143 of file auxiliary.h.
Expands the destination bounding box 'dst' such that it contains 'src'.
Definition at line 82 of file auxiliary.h.
void pcl::recognition::aux::expandBoundingBoxToContainPoint | ( | T | bbox[6], |
const T | p[3] ) |
Expands the bounding box 'bbox' such that it contains the point 'p'.
Definition at line 95 of file auxiliary.h.
Referenced by pcl::recognition::Hypothesis::computeBounds().
Sets 'm' to the 3x3 identity matrix.
Definition at line 266 of file auxiliary.h.
Referenced by axisAngleToRotationMatrix().
Returns the length of v.
Definition at line 185 of file auxiliary.h.
Referenced by axisAngleToRotationMatrix(), distance3(), and normalize3().
void pcl::recognition::aux::matrix4x4ToArray12 | ( | const Eigen::Matrix< Scalar, 4, 4 > & | src, |
Scalar | dst[12] ) |
Definition at line 375 of file auxiliary.h.
out = scalar*v.
Definition at line 230 of file auxiliary.h.
v = scalar*v.
Definition at line 221 of file auxiliary.h.
Referenced by axisAngleToRotationMatrix(), and pcl::recognition::RotationSpaceCell::Entry::computeAverageRigidTransform().
out = mat*v.
'm' is an 1D array of 9 elements treated as a 3x3 matrix (row major order).
Definition at line 274 of file auxiliary.h.
void pcl::recognition::aux::mult3x3 | ( | const T | x[3], |
const T | y[3], | ||
const T | z[3], | ||
const T | m[3][3], | ||
T | out[9] ) |
Let x, y, z be the columns of the matrix a = [x|y|z].
The method computes out = a*m. Note that 'out' is a 1D array of 9 elements and the resulting matrix is stored in row major order, i.e., the first matrix row is (out[0] out[1] out[2]), the second (out[3] out[4] out[5]) and the third (out[6] out[7] out[8]).
Definition at line 286 of file auxiliary.h.
Normalize v.
Definition at line 239 of file auxiliary.h.
References length3().
Referenced by pointsAreCoplanar().
bool pcl::recognition::aux::pointsAreCoplanar | ( | const T | p1[3], |
const T | n1[3], | ||
const T | p2[3], | ||
const T | n2[3], | ||
T | max_angle ) |
Returns true if the points 'p1' and 'p2' are co-planar and false otherwise.
The method assumes that 'n1' is a normal at 'p1' and 'n2' is a normal at 'p2'. 'max_angle' is the threshold used for the test. The bigger the value the larger the deviation between the normals can be which still leads to a positive test result. The angle has to be in radians.
Definition at line 345 of file auxiliary.h.
References clamp(), dot3(), and normalize3().
void pcl::recognition::aux::projectOnPlane3 | ( | const T | x[3], |
const T | planeNormal[3], | ||
T | out[3] ) |
Projects 'x' on the plane through 0 and with normal 'planeNormal' and saves the result in 'out'.
Definition at line 256 of file auxiliary.h.
void pcl::recognition::aux::rotationMatrixToAxisAngle | ( | const T | rotation_matrix[9], |
T | axis[3], | ||
T & | angle ) |
brief Extracts the angle-axis representation from 'rotation_matrix', i.e., computes a rotation 'axis' and an 'angle' of rotation about that axis from the provided input.
The output 'angle' is in the range [0, pi] and 'axis' is normalized.
Definition at line 437 of file auxiliary.h.
References flip3(), and toEigenMatrix3x3RowMajor().
v[0] = v[1] = v[2] = value
Definition at line 109 of file auxiliary.h.
Referenced by pcl::recognition::RotationSpaceCell::Entry::Entry().
T pcl::recognition::aux::sqr | ( | T | a | ) |
Definition at line 64 of file auxiliary.h.
Referenced by sqrDistance3().
Returns the squared Euclidean distance between a and b.
Definition at line 200 of file auxiliary.h.
References sqr().
Returns the square length of v.
Definition at line 249 of file auxiliary.h.
void pcl::recognition::aux::toEigenMatrix3x3RowMajor | ( | const T | src[9], |
Eigen::Matrix< T, 3, 3 > & | dst ) |
The method copies the input array 'src' to the eigen matrix 'dst' in row major order.
dst(0,0) = src[0]; dst(0,1) = src[1]; dst(0,2) = src[2]; dst(1,0) = src[3]; dst(1,1) = src[4]; dst(1,2) = src[5]; dst(2,0) = src[6]; dst(2,1) = src[7]; dst(2,2) = src[8];
Definition at line 401 of file auxiliary.h.
Referenced by rotationMatrixToAxisAngle().
void pcl::recognition::aux::transform | ( | const Eigen::Matrix< T, 4, 4 > & | mat, |
const pcl::PointXYZ & | p, | ||
pcl::PointXYZ & | out ) |
Compute out = (upper left 3x3 of mat)*p + last column of mat.
Definition at line 323 of file auxiliary.h.
void pcl::recognition::aux::transform | ( | const T | t[12], |
const pcl::PointXYZ & | p, | ||
T | out[3] ) |
The first 9 elements of 't' are treated as a 3x3 matrix (row major order) and the last 3 as a translation.
First, 'p' is multiplied by that matrix and then translated. The result is saved in 'out'.
Definition at line 333 of file auxiliary.h.
The first 9 elements of 't' are treated as a 3x3 matrix (row major order) and the last 3 as a translation.
First, 'p' is multiplied by that matrix and then translated. The result is saved in 'out'.
Definition at line 304 of file auxiliary.h.
Referenced by pcl::recognition::Hypothesis::computeBounds(), and pcl::recognition::Hypothesis::computeCenterOfMass().
The first 9 elements of 't' are treated as a 3x3 matrix (row major order) and the last 3 as a translation.
First, (x, y, z) is multiplied by that matrix and then translated. The result is saved in 'out'.
Definition at line 314 of file auxiliary.h.