MeVisLab Toolbox Reference
ml::PCLSupportTools Namespace Reference

A collection of tool functions used in MLPCLSupport. More...

Classes

struct  PointCloudStatistics
 Container for statistical point cloud parameters. More...
 

Enumerations

enum  PointCloudDefaultPatterns {
  Empty = 0 , OriginPoint , Triangle , Square ,
  Cube
}
 An enumerator defining some basic default patterns for point clouds. More...
 
enum  { NumberOfPointCloudDefaultPatterns = 5 }
 The number of basic default patterns for point clouds. More...
 
enum  PointCloudFillPatterns { Fill = 0 , Indexed }
 An enumerator defining some basic value fill patterns for point clouds. More...
 
enum  { NumberOfPointCloudFillPatterns = 2 }
 The number of basic value fill patterns for point clouds. More...
 
enum  { ML_PCL_NUMBER_OF_POINT_MEMBER_NAMES = 13 }
 Number of possible members of points which might appear in current implementation, also including "intensityReplacement". More...
 
enum  { ML_PCL_NUMBER_OF_FLOAT_POINT_MEMBER_NAMES = 11 }
 Possible float members of points which might appear in current implementation, also including "intensityReplacement". More...
 

Functions

template<typename POINT_CLOUD_TYPE >
PointCloudStatistics getStatistics (const POINT_CLOUD_TYPE &pointCloud, const std::string &floatPointMemberName="intensityReplacement", const bool calculateMedian=false)
 Traverses all points in the pointCloud and returns some statistical parameters.
 
template<typename POINT_CLOUD_TYPE >
float getMedian (const POINT_CLOUD_TYPE &pointCloud, const std::string &floatPointMemberName)
 Calculate the median of the member floatPointMemberName of all points and returns it as float value.
 
MLPCLSUPPORT_EXPORT MLuint64 getSigned32BitMaximumLimit ()
 Returns the maximum number of entries allowed in data structured with 32 bit signed indexing, for example in Open Inventor MFields or some members in PCL clouds.
 
MLPCLSUPPORT_EXPORT MLuint64 getUnsigned32BitMaximumLimit ()
 Returns the maximum number of entries allowed in data structured with 32 bit unsigned indexing, for example in Open Inventor MFields or some members in PCL clouds.
 
Eigen::Vector3f castToEigenVector3f (const Vector3 &mlVec)
 Convenience function to convert an ML Vector3f to an Eigen::Vector3f.

 
Eigen::Vector4f castToEigenVector4f (const Vector4 &mlVec)
 Convenience function to convert an ML Vector4f to an Eigen::Vector4f.

 
MLPCLSUPPORT_EXPORT void castToStdVector (const Eigen::VectorXf &eigenVec, std::vector< MLfloat > &stdVec)
 Convenience function to convert an Eigen::VectorXf to a std::vector<MLfloat>, e.g.
 
size_t getMaximumNumberOfScalarPointMembers ()
 From the point cloud type with the largest number of scalar members returns the number of scalar values which exist in the corresponding point type, regardless of their types or whether they are stored in structures, arrays or in single members.
 
template<typename PCL_OBJECT_PTR_TYPE >
void createEmptyPCLObject (PCL_OBJECT_PTR_TYPE &retPCLObjectPtr)
 Creates an empty point cloud of type POINT_CLOUD_PTR_TYPE.
 
template<typename POINT_CLOUD_TYPE >
void appendPoint (POINT_CLOUD_TYPE &pc, const Vector3f &pos, float fillValue)
 Appends a new point to pc with data[0-2] given by pos and data[3] by fillValue; does nothing if pc is nullptr.
 
template<typename POINT_CLOUD_TYPE >
void appendFillPattern (POINT_CLOUD_TYPE &pc, PointCloudDefaultPatterns pattern, PointCloudFillPatterns fillMode, float fillValue=0.f)
 Creates a PointCloud point cloud filled with a set of points defined by pattern and fillMode; does nothing if pc is nullptr.
 
bool fourFloatsDiffer (const float data1[4], const float data2[4], double epsilon=FLT_EPSILON)
 Returns true if differences between corresponding data1 and data2 entries are >= epsilon, otherwise false is returned.
 
template<typename POINT_TYPE >
void getPCLPointAsFormattedString (const POINT_TYPE &point, std::string &formatStr, int numDecimalPlaces, size_t pointIndex)
 Replaces placeholders in formatStr with values from the given point.
 
template<typename POINT_CLOUD_TYPE >
std::string getPCLPointListAsString (const POINT_CLOUD_TYPE &pointCloud, MLint maxNumShownPoints=ML_INT64_MAX, MLint indexOfFirstPoint=0, bool showIndices=true, const std::string &lineSeparator="\n", int numDecimalPlaces=-1, const std::string &pointsPrintFormatStr="")
 Converts at most maxNumShownPoints from pointCloud starting at position indexOfFirstPoint into a string which is separated between points with lineSeparator, each line will contain the x, y, z, and data[3] value of the corresponding point and a prefix showing the current index position of the point in pointCloud.points if showIndices is true.
 
template<typename POINT_CLOUD_TYPE >
std::string getPointStructureT (const POINT_CLOUD_TYPE &pointCloud)
 Returns an empty string if pointCloud.points are empty, otherwise a concatenated, comma separated string of string descriptions of all members of a point of this point cloud.
 
MLPCLSUPPORT_EXPORT std::string getPCLVerticesAsString (const std::vector< pcl::Vertices > &vertices, MLint maxNumShownVertices=ML_INT64_MAX, MLint indexOfFirstVertex=0, bool showIndices=true, const std::string &lineSeparator=_PCLSupportTools_NewLineDefaultArgumentString)
 Converts at most maxNumShownVertices vertices from vertices starting at position indexOfFirstVertex into a string which is separated between points with lineSeparator, each line will contain the x, y, z, and data[3] value of the corresponding vertex and a prefix showing the current index position of the point in pointCloud.points if showIndices is true.
 
MLPCLSUPPORT_EXPORT std::string getPCLIndicesAsString (const std::vector< int > &indices, MLint maxNumShownIndices, MLint indexOfFirstIndex, bool showIndices, const std::string &lineSeparator=_PCLSupportTools_NewLineDefaultArgumentString)
 Converts at most maxNumShownIndices indices from indices starting at position indexOfFirstIndex into a string which are separated with lineSeparator, each line will contain the index value and a prefix showing the current index position of the index in indices if showIndices is true.
 
MLPCLSUPPORT_EXPORT void PCLExtractSubIndices (const std::vector< int > &subIndices, std::vector< int > &indices)
 Extract all indices from indices if they are listed in subIndices in the order as given in subIndices; indices out of range in subIndices are ignored.
 
MLPCLSUPPORT_EXPORT std::string getPointFieldValueAsString (std::uint8_t fd, const std::uint8_t *dataPtr, int numDecimalPlaces=-1)
 Reinterprets the data at position dataPtr as a pcl::PointField::PointFieldTypes enumerator given by fd and converts the content to a human readable string.
 
MLPCLSUPPORT_EXPORT std::string getPointFieldDataTypeString (std::uint8_t fd, bool aligned)
 Returns a human readable string for a pcl::PCLPointField::PointFieldTypes enumerator.
 
MLPCLSUPPORT_EXPORT std::string getCloudDataString (const MLPolygonMesh &polygonMesh, MLint maxNumShownVertices=ML_INT64_MAX, MLint indexOfFirstVertex=0, bool showIndices=true, const std::string &lineSeparator=_PCLSupportTools_NewLineDefaultArgumentString, int numDecimalPlaces=-1)
 Converts the cloud data of polygonMesh to a human readable string.
 
MLPCLSUPPORT_EXPORT std::string getCloudFieldsString (const std::vector< pcl::PCLPointField > &fields)
 Converts the pointField vector fields to a human readable string.
 
template<typename POINT_CLOUD_TYPE >
SubImageBoxd getBoxForPointCloud (const POINT_CLOUD_TYPE &inputPointCloud)
 Returns an ML SubImageBoxd whose extents are sufficient in that way that all points of inputPointCloud are located inside or exactly on the box borders.
 
template<typename POINT_CLOUD_TYPE >
SubImageBox getBoxForPointCloud (const POINT_CLOUD_TYPE &pointCloud, Vector3f &pointCloudOrigin, bool includeAll)
 Returns an ML SubImageBox corresponding to pointCloud.
 
MLPCLSUPPORT_EXPORT size_t getByteOffset (const pcl::PointXYZ &pnt, const std::string &pointMemberName)
 Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.
 
MLPCLSUPPORT_EXPORT size_t getByteOffset (const pcl::PointXYZLNormal &pnt, const std::string &pointMemberName)
 Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.
 
MLPCLSUPPORT_EXPORT size_t getByteOffset (const pcl::PointXYZRGBNormal &pnt, const std::string &pointMemberName)
 Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.
 
MLPCLSUPPORT_EXPORT size_t getByteOffset (const pcl::PointXYZINormal &pnt, const std::string &pointMemberName)
 Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.
 
MLPCLSUPPORT_EXPORT std::string getPCLPointAsString (const pcl::PointXYZ &point, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getPCLPointAsString (const pcl::PointXYZLNormal &point, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getPCLPointAsString (const pcl::PointXYZRGBNormal &point, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getPCLPointAsString (const pcl::PointXYZINormal &point, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberNameAsString (const pcl::PointXYZ &, size_t memberIdx)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberNameAsString (const pcl::PointXYZLNormal &, size_t memberIdx)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberNameAsString (const pcl::PointXYZRGBNormal &, size_t memberIdx)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberNameAsString (const pcl::PointXYZINormal &, size_t memberIdx)
 
size_t getNumberOfScalarPointMembers (const pcl::PointXYZ &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZ &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZPtr &)
 
size_t getNumberOfScalarPointMembers (const pcl::PointXYZLNormal &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZLNormal &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZLNormalPtr &)
 
size_t getNumberOfScalarPointMembers (const pcl::PointXYZRGBNormal &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZRGBNormal &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZRGBNormalPtr &)
 
size_t getNumberOfScalarPointMembers (const pcl::PointXYZINormal &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZINormal &)
 
size_t getNumberOfScalarPointMembers (const MLPointCloudXYZINormalPtr &)
 
bool hasNormals (const pcl::PointXYZ &)
 Returns true if the point or point type contains normal fields/members, otherwise false,.
 
bool hasNormals (const MLPointCloudXYZ &)
 
bool hasNormals (const MLPointCloudXYZPtr &)
 
bool hasNormals (const pcl::PointXYZLNormal &)
 
bool hasNormals (const MLPointCloudXYZLNormal &)
 
bool hasNormals (const MLPointCloudXYZLNormalPtr &)
 
bool hasNormals (const pcl::PointXYZRGBNormal &)
 
bool hasNormals (const MLPointCloudXYZRGBNormal &)
 
bool hasNormals (const MLPointCloudXYZRGBNormalPtr &)
 
bool hasNormals (const pcl::PointXYZINormal &)
 
bool hasNormals (const MLPointCloudXYZINormal &)
 
bool hasNormals (const MLPointCloudXYZINormalPtr &)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberValueAsString (const pcl::PointXYZ &p, size_t memberIdx, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberValueAsString (const pcl::PointXYZLNormal &p, size_t memberIdx, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberValueAsString (const pcl::PointXYZRGBNormal &p, size_t memberIdx, int numDecimalPlaces=-1)
 
MLPCLSUPPORT_EXPORT std::string getScalarMemberValueAsString (const pcl::PointXYZINormal &p, size_t memberIdx, int numDecimalPlaces=-1)
 
void setPointFromFields (pcl::PointXYZ &pnt, const std::vector< DoubleField * > &constantFields)
 Copy states of constantFields to the corresponding member of pnt; the contantFields vector must have a sufficient size for all members of the point cloud points, accesses out-of range are not handled.
 
void setPointFromFields (pcl::PointXYZLNormal &pnt, const std::vector< DoubleField * > &constantFields)
 
void setPointFromFields (pcl::PointXYZRGBNormal &pnt, const std::vector< DoubleField * > &constantFields)
 
void setPointFromFields (pcl::PointXYZINormal &pnt, const std::vector< DoubleField * > &constantFields)
 
void setPointFromScalar (pcl::PointXYZ &pnt, const float val)
 Copy a scalar value into all point fields.
 
void setPointFromScalar (pcl::PointXYZLNormal &pnt, const float val)
 
void setPointFromScalar (pcl::PointXYZRGBNormal &pnt, const float val)
 
void setPointFromScalar (pcl::PointXYZINormal &pnt, const float val)
 
void setFieldsFromPoint (const pcl::PointXYZ &pnt, std::vector< DoubleField * > &resultFields)
 Set resultFields to the corresponding member states of pnt; the resultFields vector must have a sufficient size for all members of the point cloud points, accesses out-of range are not handled.
 
void setFieldsFromPoint (const pcl::PointXYZLNormal &pnt, std::vector< DoubleField * > &resultFields)
 
void setFieldsFromPoint (const pcl::PointXYZRGBNormal &pnt, std::vector< DoubleField * > &resultFields)
 
void setFieldsFromPoint (const pcl::PointXYZINormal &pnt, std::vector< DoubleField * > &resultFields)
 
MLPointCloudXYZPtr createEmptyXYZPointCloud ()
 Creates an empty PointCloudXYZ point cloud.
 
MLPointCloudXYZLNormalPtr createEmptyXYZLNormalPointCloud ()
 Creates an empty PointCloudXYZLNormal point cloud.
 
MLPointCloudXYZRGBNormalPtr createEmptyXYZRGBNormalPointCloud ()
 Creates an empty PointCloudXYZRGBNormal point cloud.
 
MLPointCloudXYZINormalPtr createEmptyXYZINormalPointCloud ()
 Creates an empty PointCloudXYZLNormal point cloud.
 
MLPolygonMeshPtr createEmptyPolygonMesh ()
 Creates an empty pcl::PolygonMesh object.
 
template<typename POINT_TYPE1 , typename POINT_TYPE2 >
bool doPCLPointNonDataMembersDiffer (const POINT_TYPE1 &, const POINT_TYPE2 &, double=FLT_EPSILON)
 Compare all non data members of all supported point types with each other.
 
bool doPCLPointNonDataMembersDiffer (const pcl::PointXYZ &, const pcl::PointXYZ &, double=FLT_EPSILON)
 Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.
 
bool doPCLPointNonDataMembersDiffer (const pcl::PointXYZLNormal &point1, const pcl::PointXYZLNormal &point2, double epsilon=FLT_EPSILON)
 Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.
 
bool doPCLPointNonDataMembersDiffer (const pcl::PointXYZRGBNormal &point1, const pcl::PointXYZRGBNormal &point2, double epsilon=FLT_EPSILON)
 Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.
 
bool doPCLPointNonDataMembersDiffer (const pcl::PointXYZINormal &point1, const pcl::PointXYZINormal &point2, double epsilon=FLT_EPSILON)
 Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.
 
void setIntensityReplacement (pcl::PointXYZ &, float=1.f, MLuint8=0xff)
 Sets a scalar value in a member which can be used as storage for an additional value, such as the curvature in a pcl::PointXYZLNormal or in RGB members.
 
void setIntensityReplacement (pcl::PointXYZLNormal &p, float value=1.f, MLuint8=0xff)
 
void setIntensityReplacement (pcl::PointXYZRGBNormal &p, float value=1.f, MLuint8 opacity=0xff)
 
void setIntensityReplacement (pcl::PointXYZINormal &p, float value=1.f, MLuint8=0xff)
 
float getIntensityReplacement (const pcl::PointXYZ &)
 Gets the scalar value in a member which is considered as storage for an additional value, such as the curvature in a pcl::PointXYZLNormal or in RGB members.
 
float getIntensityReplacement (const pcl::PointXYZLNormal &p)
 
float getIntensityReplacement (const pcl::PointXYZRGBNormal &p)
 
float getIntensityReplacement (const pcl::PointXYZINormal &p)
 
float getCurvature (const pcl::PointXYZ &)
 Gets/sets the curvature value as float if the point has one, otherwise return 0 (for example in the case of pcl::PointXYZ or do nothing in set).
 
float getCurvature (const pcl::PointXYZLNormal &p)
 
float getCurvature (const pcl::PointXYZRGBNormal &p)
 
float getCurvature (const pcl::PointXYZINormal &p)
 
void setCurvature (pcl::PointXYZ &, float)
 
void setCurvature (pcl::PointXYZLNormal &p, float curvature)
 
void setCurvature (pcl::PointXYZRGBNormal &p, float curvature)
 
void setCurvature (pcl::PointXYZINormal &p, float curvature)
 
unsigned int getPointRGBA (const pcl::PointXYZ &)
 Get the rgba value from PCL point if it has that member otherwise get 0u; for set functionality set that member or do nothing otherwise.
 
unsigned int getPointRGBA (const pcl::PointXYZINormal &)
 
unsigned int getPointRGBA (const pcl::PointXYZRGBNormal &rgbaPnt)
 
unsigned int getPointRGBA (const pcl::PointXYZLNormal &)
 
void setPointRGBA (pcl::PointXYZ &, MLuint32)
 
void setPointRGBA (pcl::PointXYZINormal &, MLuint32)
 
void setPointRGBA (pcl::PointXYZRGBNormal &rgbaPnt, MLuint32 srcVal)
 
void setPointRGBA (pcl::PointXYZLNormal &, MLuint32)
 
void setPointNormal (pcl::PointXYZ &, float, float, float)
 Sets the normal fields normal_x, normal_y, normal_z of a point from nx, ny, nz if the point contains such members; if the point has no normal members then the call is ignored, for example in the case of pcl::PointXYZ.
 
void setPointNormal (pcl::PointXYZLNormal &p, float nx, float ny, float nz)
 
void setPointNormal (pcl::PointXYZRGBNormal &p, float nx, float ny, float nz)
 
void setPointNormal (pcl::PointXYZINormal &p, float nx, float ny, float nz)
 
void getPointNormal (const pcl::PointXYZ &, float &nx, float &ny, float &nz)
 Returns the normal field members normal_x, normal_y, normal_z of a point p in nx, ny, nz if the point contains such members; if the point has no normal members then in nx, ny, and nz 0 is returned, for example in the case of pcl::PointXYZ.
 
void getPointNormal (const pcl::PointXYZLNormal &p, float &nx, float &ny, float &nz)
 
void getPointNormal (const pcl::PointXYZRGBNormal &p, float &nx, float &ny, float &nz)
 
void getPointNormal (const pcl::PointXYZINormal &p, float &nx, float &ny, float &nz)
 
bool hasNormal (const pcl::PointXYZ &)
 Returns true if the passed point has a normal, otherwise false.
 
bool hasNormal (const pcl::PointXYZLNormal &)
 
bool hasNormal (const pcl::PointXYZRGBNormal &)
 
bool hasNormal (const pcl::PointXYZINormal &)
 
bool hasLabel (const pcl::PointXYZ &)
 Returns true if the passed point has a label field, otherwise false.
 
bool hasLabel (const pcl::PointXYZLNormal &)
 
bool hasLabel (const pcl::PointXYZRGBNormal &)
 
bool hasLabel (const pcl::PointXYZINormal &)
 
bool hasRGBA (const pcl::PointXYZ &)
 Returns true if the passed point has an rgba field, otherwise false.
 
bool hasRGBA (const pcl::PointXYZLNormal &)
 
bool hasRGBA (const pcl::PointXYZRGBNormal &)
 
bool hasRGBA (const pcl::PointXYZINormal &)
 
bool hasIntensity (const pcl::PointXYZ &)
 Returns true if the passed point has an intensity field, otherwise false.
 
bool hasIntensity (const pcl::PointXYZLNormal &)
 
bool hasIntensity (const pcl::PointXYZRGBNormal &)
 
bool hasIntensity (const pcl::PointXYZINormal &)
 
bool hasCurvature (const pcl::PointXYZ &)
 Returns true if the passed point has a curvature field, otherwise false.
 
bool hasCurvature (const pcl::PointXYZLNormal &)
 
bool hasCurvature (const pcl::PointXYZRGBNormal &)
 
bool hasCurvature (const pcl::PointXYZINormal &)
 
bool hasIntensityReplacement (const pcl::PointXYZ &)
 Returns true if the passed point has any field which can be interpreted as an intensity replacement field, otherwise false.
 
bool hasIntensityReplacement (const pcl::PointXYZLNormal &)
 
bool hasIntensityReplacement (const pcl::PointXYZRGBNormal &)
 
bool hasIntensityReplacement (const pcl::PointXYZINormal &)
 

Variables

MLPCLSUPPORT_EXPORT const char *const PointMemberNames [ML_PCL_NUMBER_OF_POINT_MEMBER_NAMES]
 Possible members of points as strings which might appear in current implementation.
 
MLPCLSUPPORT_EXPORT const char *const FloatPointMemberNames [ML_PCL_NUMBER_OF_FLOAT_POINT_MEMBER_NAMES]
 Number of possible float members as strings which might appear in current implementation.
 

Detailed Description

A collection of tool functions used in MLPCLSupport.

Enumeration Type Documentation

◆ anonymous enum

The number of basic default patterns for point clouds.

Enumerator
NumberOfPointCloudDefaultPatterns 

Definition at line 402 of file mlPCLSupportTools.h.

◆ anonymous enum

The number of basic value fill patterns for point clouds.

Enumerator
NumberOfPointCloudFillPatterns 

Definition at line 416 of file mlPCLSupportTools.h.

◆ anonymous enum

Number of possible members of points which might appear in current implementation, also including "intensityReplacement".

Enumerator
ML_PCL_NUMBER_OF_POINT_MEMBER_NAMES 

Definition at line 1295 of file mlPCLSupportTools.h.

◆ anonymous enum

Possible float members of points which might appear in current implementation, also including "intensityReplacement".

Enumerator
ML_PCL_NUMBER_OF_FLOAT_POINT_MEMBER_NAMES 

Definition at line 1308 of file mlPCLSupportTools.h.

◆ PointCloudDefaultPatterns

An enumerator defining some basic default patterns for point clouds.

Enumerator
Empty 
OriginPoint 
Triangle 
Square 
Cube 

Definition at line 391 of file mlPCLSupportTools.h.

◆ PointCloudFillPatterns

An enumerator defining some basic value fill patterns for point clouds.

Enumerator
Fill 
Indexed 

Definition at line 409 of file mlPCLSupportTools.h.

Function Documentation

◆ appendFillPattern()

void ml::PCLSupportTools::appendFillPattern ( POINT_CLOUD_TYPE & pc,
PointCloudDefaultPatterns pattern,
PointCloudFillPatterns fillMode,
float fillValue = 0.f )
inline

Creates a PointCloud point cloud filled with a set of points defined by pattern and fillMode; does nothing if pc is nullptr.

Definition at line 443 of file mlPCLSupportTools.h.

References appendFillPattern(), appendPoint(), Cube, Fill, Indexed, ML_BAD_PARAMETER, ML_PRINT_ERROR, mlrange_cast(), OriginPoint, Square, and Triangle.

Referenced by appendFillPattern().

◆ appendPoint()

void ml::PCLSupportTools::appendPoint ( POINT_CLOUD_TYPE & pc,
const Vector3f & pos,
float fillValue )
inline

Appends a new point to pc with data[0-2] given by pos and data[3] by fillValue; does nothing if pc is nullptr.

Definition at line 425 of file mlPCLSupportTools.h.

References appendPoint(), mlrange_cast(), ml::Vector3DataContainer< DT >::x, ml::Vector3DataContainer< DT >::y, and ml::Vector3DataContainer< DT >::z.

Referenced by appendFillPattern(), and appendPoint().

◆ castToEigenVector3f()

Eigen::Vector3f ml::PCLSupportTools::castToEigenVector3f ( const Vector3 & mlVec)
inline

Convenience function to convert an ML Vector3f to an Eigen::Vector3f.

Definition at line 43 of file mlPCLSupportTools.h.

References castToEigenVector3f(), and mlrange_cast().

Referenced by castToEigenVector3f().

◆ castToEigenVector4f()

Eigen::Vector4f ml::PCLSupportTools::castToEigenVector4f ( const Vector4 & mlVec)
inline

Convenience function to convert an ML Vector4f to an Eigen::Vector4f.

Definition at line 53 of file mlPCLSupportTools.h.

References castToEigenVector4f(), and mlrange_cast().

Referenced by castToEigenVector4f().

◆ castToStdVector()

MLPCLSUPPORT_EXPORT void ml::PCLSupportTools::castToStdVector ( const Eigen::VectorXf & eigenVec,
std::vector< MLfloat > & stdVec )

Convenience function to convert an Eigen::VectorXf to a std::vector<MLfloat>, e.g.

for use with FloatMultiField.

References castToStdVector().

Referenced by castToStdVector().

◆ createEmptyPCLObject()

void ml::PCLSupportTools::createEmptyPCLObject ( PCL_OBJECT_PTR_TYPE & retPCLObjectPtr)
inline

◆ createEmptyPolygonMesh()

MLPolygonMeshPtr ml::PCLSupportTools::createEmptyPolygonMesh ( )
inline

Creates an empty pcl::PolygonMesh object.

Definition at line 380 of file mlPCLSupportTools.h.

References createEmptyPCLObject(), createEmptyPolygonMesh(), and mlrange_cast().

Referenced by createEmptyPolygonMesh().

◆ createEmptyXYZINormalPointCloud()

MLPointCloudXYZINormalPtr ml::PCLSupportTools::createEmptyXYZINormalPointCloud ( )
inline

Creates an empty PointCloudXYZLNormal point cloud.

Definition at line 371 of file mlPCLSupportTools.h.

References createEmptyPCLObject(), createEmptyXYZINormalPointCloud(), and mlrange_cast().

Referenced by createEmptyXYZINormalPointCloud().

◆ createEmptyXYZLNormalPointCloud()

MLPointCloudXYZLNormalPtr ml::PCLSupportTools::createEmptyXYZLNormalPointCloud ( )
inline

Creates an empty PointCloudXYZLNormal point cloud.

Definition at line 353 of file mlPCLSupportTools.h.

References createEmptyPCLObject(), createEmptyXYZLNormalPointCloud(), and mlrange_cast().

Referenced by createEmptyXYZLNormalPointCloud().

◆ createEmptyXYZPointCloud()

MLPointCloudXYZPtr ml::PCLSupportTools::createEmptyXYZPointCloud ( )
inline

Creates an empty PointCloudXYZ point cloud.

Definition at line 344 of file mlPCLSupportTools.h.

References createEmptyPCLObject(), createEmptyXYZPointCloud(), and mlrange_cast().

Referenced by createEmptyXYZPointCloud().

◆ createEmptyXYZRGBNormalPointCloud()

MLPointCloudXYZRGBNormalPtr ml::PCLSupportTools::createEmptyXYZRGBNormalPointCloud ( )
inline

Creates an empty PointCloudXYZRGBNormal point cloud.

Definition at line 362 of file mlPCLSupportTools.h.

References createEmptyPCLObject(), createEmptyXYZRGBNormalPointCloud(), and mlrange_cast().

Referenced by createEmptyXYZRGBNormalPointCloud().

◆ doPCLPointNonDataMembersDiffer() [1/5]

bool ml::PCLSupportTools::doPCLPointNonDataMembersDiffer ( const pcl::PointXYZ & ,
const pcl::PointXYZ & ,
double = FLT_EPSILON )
inline

Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.

Definition at line 527 of file mlPCLSupportTools.h.

References doPCLPointNonDataMembersDiffer().

◆ doPCLPointNonDataMembersDiffer() [2/5]

bool ml::PCLSupportTools::doPCLPointNonDataMembersDiffer ( const pcl::PointXYZINormal & point1,
const pcl::PointXYZINormal & point2,
double epsilon = FLT_EPSILON )
inline

Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.

Definition at line 564 of file mlPCLSupportTools.h.

References doPCLPointNonDataMembersDiffer(), fourFloatsDiffer(), MLAbs(), and mlrange_cast().

◆ doPCLPointNonDataMembersDiffer() [3/5]

bool ml::PCLSupportTools::doPCLPointNonDataMembersDiffer ( const pcl::PointXYZLNormal & point1,
const pcl::PointXYZLNormal & point2,
double epsilon = FLT_EPSILON )
inline

Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.

Definition at line 538 of file mlPCLSupportTools.h.

References doPCLPointNonDataMembersDiffer(), fourFloatsDiffer(), MLAbs(), and mlrange_cast().

◆ doPCLPointNonDataMembersDiffer() [4/5]

bool ml::PCLSupportTools::doPCLPointNonDataMembersDiffer ( const pcl::PointXYZRGBNormal & point1,
const pcl::PointXYZRGBNormal & point2,
double epsilon = FLT_EPSILON )
inline

Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned.

Definition at line 551 of file mlPCLSupportTools.h.

References doPCLPointNonDataMembersDiffer(), fourFloatsDiffer(), MLAbs(), and mlrange_cast().

◆ doPCLPointNonDataMembersDiffer() [5/5]

bool ml::PCLSupportTools::doPCLPointNonDataMembersDiffer ( const POINT_TYPE1 & ,
const POINT_TYPE2 & ,
double = FLT_EPSILON )
inline

Compare all non data members of all supported point types with each other.

Returns true if differences between corresponding non data members of point1 and point2 are found which are >= epsilon, otherwise false is returned; this is the template default implementation which always returns true; all cases which possibly may return false must be implemented specialized.

Definition at line 516 of file mlPCLSupportTools.h.

References doPCLPointNonDataMembersDiffer().

Referenced by doPCLPointNonDataMembersDiffer(), doPCLPointNonDataMembersDiffer(), doPCLPointNonDataMembersDiffer(), doPCLPointNonDataMembersDiffer(), and doPCLPointNonDataMembersDiffer().

◆ fourFloatsDiffer()

bool ml::PCLSupportTools::fourFloatsDiffer ( const float data1[4],
const float data2[4],
double epsilon = FLT_EPSILON )
inline

Returns true if differences between corresponding data1 and data2 entries are >= epsilon, otherwise false is returned.

Definition at line 496 of file mlPCLSupportTools.h.

References fourFloatsDiffer(), MLAbs(), and mlrange_cast().

Referenced by doPCLPointNonDataMembersDiffer(), doPCLPointNonDataMembersDiffer(), doPCLPointNonDataMembersDiffer(), and fourFloatsDiffer().

◆ getBoxForPointCloud() [1/2]

SubImageBoxd ml::PCLSupportTools::getBoxForPointCloud ( const POINT_CLOUD_TYPE & inputPointCloud)
inline

Returns an ML SubImageBoxd whose extents are sufficient in that way that all points of inputPointCloud are located inside or exactly on the box borders.

If inputPointCloud is empty then an empty box is returned.

Definition at line 1207 of file mlPCLSupportTools.h.

References getBoxForPointCloud(), ML_FLOAT_MAX, mlrange_cast(), and ml::SubImageBoxd::v1.

Referenced by getBoxForPointCloud(), and getBoxForPointCloud().

◆ getBoxForPointCloud() [2/2]

SubImageBox ml::PCLSupportTools::getBoxForPointCloud ( const POINT_CLOUD_TYPE & pointCloud,
Vector3f & pointCloudOrigin,
bool includeAll )
inline

Returns an ML SubImageBox corresponding to pointCloud.

If includeAll is false then the returned box is large enough that all coordinates of point from pointCloud can be c-cast to inside the box, however, it may happen that these coordinates are outside the box in continuous space. If includeAll is true then the returned box is large enough that all coordinates of point from pointCloud are inside the box even is checked in continuous space. If inputPointCloud is empty then an empty box is returned. pointCloudOrigin is set to the smallest value of all three dimensions found found in all points or (0,0,0) if point cloud is empty.

Definition at line 1253 of file mlPCLSupportTools.h.

References getBoxForPointCloud(), and mlrange_cast().

◆ getByteOffset() [1/4]

MLPCLSUPPORT_EXPORT size_t ml::PCLSupportTools::getByteOffset ( const pcl::PointXYZ & pnt,
const std::string & pointMemberName )

Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.

References getByteOffset().

Referenced by getByteOffset(), getByteOffset(), getByteOffset(), and getByteOffset().

◆ getByteOffset() [2/4]

MLPCLSUPPORT_EXPORT size_t ml::PCLSupportTools::getByteOffset ( const pcl::PointXYZINormal & pnt,
const std::string & pointMemberName )

Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.

References getByteOffset().

◆ getByteOffset() [3/4]

MLPCLSUPPORT_EXPORT size_t ml::PCLSupportTools::getByteOffset ( const pcl::PointXYZLNormal & pnt,
const std::string & pointMemberName )

Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.

References getByteOffset().

◆ getByteOffset() [4/4]

MLPCLSUPPORT_EXPORT size_t ml::PCLSupportTools::getByteOffset ( const pcl::PointXYZRGBNormal & pnt,
const std::string & pointMemberName )

Returns the offset in bytes between the given member described as string and the first member in the point in bytes; if any member cannot be found then ML_SIZE_T_MAX is returned.

References getByteOffset().

◆ getCloudDataString()

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getCloudDataString ( const MLPolygonMesh & polygonMesh,
MLint maxNumShownVertices = ML_INT64_MAX,
MLint indexOfFirstVertex = 0,
bool showIndices = true,
const std::string & lineSeparator = _PCLSupportTools_NewLineDefaultArgumentString,
int numDecimalPlaces = -1 )

Converts the cloud data of polygonMesh to a human readable string.

Parameters
polygonMeshThe polygon mesh whose cloud data it to be converted to a human readable string string.
maxNumShownVerticesThe maximum number of vertices to be printed, starting with indexOfFirstVertex.
indexOfFirstVertexThe index of the first vertex from which the vertex vector is printed.
showIndicesIf enabled then the vertex position and a ":" is printed as prefix before each point line, otherwise only the vertex position and values are printed.
lineSeparatorA string used to separate subsequent point string, usually something like a newline or so.
numDecimalPlacesThe maximum number of digits to be printed after the comma or full precision of the given field type if -1.

References getCloudDataString().

Referenced by getCloudDataString().

◆ getCloudFieldsString()

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getCloudFieldsString ( const std::vector< pcl::PCLPointField > & fields)

Converts the pointField vector fields to a human readable string.

References getCloudFieldsString().

Referenced by getCloudFieldsString().

◆ getCurvature() [1/4]

float ml::PCLSupportTools::getCurvature ( const pcl::PointXYZ & )
inline

Gets/sets the curvature value as float if the point has one, otherwise return 0 (for example in the case of pcl::PointXYZ or do nothing in set).

Definition at line 637 of file mlPCLSupportTools.h.

References getCurvature().

Referenced by getCurvature(), getCurvature(), getCurvature(), and getCurvature().

◆ getCurvature() [2/4]

float ml::PCLSupportTools::getCurvature ( const pcl::PointXYZINormal & p)
inline

Definition at line 650 of file mlPCLSupportTools.h.

References getCurvature().

◆ getCurvature() [3/4]

float ml::PCLSupportTools::getCurvature ( const pcl::PointXYZLNormal & p)
inline

Definition at line 642 of file mlPCLSupportTools.h.

References getCurvature().

◆ getCurvature() [4/4]

float ml::PCLSupportTools::getCurvature ( const pcl::PointXYZRGBNormal & p)
inline

Definition at line 646 of file mlPCLSupportTools.h.

References getCurvature().

◆ getIntensityReplacement() [1/4]

float ml::PCLSupportTools::getIntensityReplacement ( const pcl::PointXYZ & )
inline

Gets the scalar value in a member which is considered as storage for an additional value, such as the curvature in a pcl::PointXYZLNormal or in RGB members.

If the point has no such member then 0 is returned, for example in the case of pcl::PointXYZ.

Definition at line 612 of file mlPCLSupportTools.h.

References getIntensityReplacement().

Referenced by getIntensityReplacement(), getIntensityReplacement(), getIntensityReplacement(), getIntensityReplacement(), and getPCLPointAsFormattedString().

◆ getIntensityReplacement() [2/4]

float ml::PCLSupportTools::getIntensityReplacement ( const pcl::PointXYZINormal & p)
inline

Definition at line 625 of file mlPCLSupportTools.h.

References getIntensityReplacement().

◆ getIntensityReplacement() [3/4]

float ml::PCLSupportTools::getIntensityReplacement ( const pcl::PointXYZLNormal & p)
inline

Definition at line 617 of file mlPCLSupportTools.h.

References getIntensityReplacement().

◆ getIntensityReplacement() [4/4]

float ml::PCLSupportTools::getIntensityReplacement ( const pcl::PointXYZRGBNormal & p)
inline

Definition at line 621 of file mlPCLSupportTools.h.

References getIntensityReplacement().

◆ getMaximumNumberOfScalarPointMembers()

size_t ml::PCLSupportTools::getMaximumNumberOfScalarPointMembers ( )
inline

From the point cloud type with the largest number of scalar members returns the number of scalar values which exist in the corresponding point type, regardless of their types or whether they are stored in structures, arrays or in single members.

Definition at line 138 of file mlPCLSupportTools.h.

References getMaximumNumberOfScalarPointMembers().

Referenced by getMaximumNumberOfScalarPointMembers().

◆ getMedian()

float ml::PCLSupportTools::getMedian ( const POINT_CLOUD_TYPE & pointCloud,
const std::string & floatPointMemberName )
inline

Calculate the median of the member floatPointMemberName of all points and returns it as float value.

Definition at line 110 of file mlPCLSupportStatistics.h.

References getMedian(), ML_SIZE_T_MAX, and mlrange_cast().

Referenced by getMedian().

◆ getNumberOfScalarPointMembers() [1/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZ & )
inline

Definition at line 98 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [2/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZINormal & )
inline

Definition at line 110 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [3/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZINormalPtr & )
inline

Definition at line 111 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [4/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZLNormal & )
inline

Definition at line 102 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [5/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZLNormalPtr & )
inline

Definition at line 103 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [6/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZPtr & )
inline

Definition at line 99 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [7/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZRGBNormal & )
inline

Definition at line 106 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [8/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const MLPointCloudXYZRGBNormalPtr & )
inline

Definition at line 107 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [9/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const pcl::PointXYZ & )
inline

◆ getNumberOfScalarPointMembers() [10/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const pcl::PointXYZINormal & )
inline

Definition at line 109 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [11/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const pcl::PointXYZLNormal & )
inline

Definition at line 101 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getNumberOfScalarPointMembers() [12/12]

size_t ml::PCLSupportTools::getNumberOfScalarPointMembers ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 105 of file mlPCLSupportTools.h.

References getNumberOfScalarPointMembers().

◆ getPCLIndicesAsString()

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPCLIndicesAsString ( const std::vector< int > & indices,
MLint maxNumShownIndices,
MLint indexOfFirstIndex,
bool showIndices,
const std::string & lineSeparator = _PCLSupportTools_NewLineDefaultArgumentString )

Converts at most maxNumShownIndices indices from indices starting at position indexOfFirstIndex into a string which are separated with lineSeparator, each line will contain the index value and a prefix showing the current index position of the index in indices if showIndices is true.

Parameters
indicesThe index vector whose indices shall be printed into a string.
maxNumShownIndicesThe maximum number of indices to be printed, starting with indexOfFirstIndex.
indexOfFirstIndexThe index of the first index from which the index vector is printed.
showIndicesIf enabled then the index position and a ":" is printed as prefix before each point line, otherwise only the index position and values are printed.
lineSeparatorA string used to separate subsequent point string, usually something like a newline or so. return The string containing the printed numbers.

References getPCLIndicesAsString().

Referenced by getPCLIndicesAsString().

◆ getPCLPointAsFormattedString()

template<typename POINT_TYPE >
void ml::PCLSupportTools::getPCLPointAsFormattedString ( const POINT_TYPE & point,
std::string & formatStr,
int numDecimalPlaces,
size_t pointIndex )
inline

Replaces placeholders in formatStr with values from the given point.

Parameters
pointThe point whose field values shall be used to replace placeholders in formatStr.
formatStrThe following substrings are replaced with field values from point, or, if the field value is not in point, with "": , $(data[0]): x-component of point coordinate , $(data[1]): y-component of point coordinate , $(data[2]): z-component of point coordinate $(data[3]): fourth component of point coordinate , $(data_n[0]): x-component of normal , $(data_n[1]): y-component of normal , $(data_n[2]): z-component of normal $(data_n[3]): fourth component of normal : intensity replacement value. : curvature. : rgba as hexadecimal value if available otherwise 0x00000000. : intensity value. : label as integer. : The index of the point in the point cloud.
numDecimalPlacesThe maximum number of digits to be printed after the comma or full precision of the given field type if -1.
pointIndexThe index of the point in the point cloud.

Definition at line 871 of file mlPCLSupportTools.h.

References getIntensityReplacement(), getPCLPointAsFormattedString(), getScalarMemberValueAsString(), hasIntensity(), hasIntensityReplacement(), hasLabel(), hasRGBA(), and mlrange_cast().

Referenced by getPCLPointAsFormattedString(), and getPCLPointListAsString().

◆ getPCLPointAsString() [1/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPCLPointAsString ( const pcl::PointXYZ & point,
int numDecimalPlaces = -1 )

Prints the members of point into the returned string, numDecimalPlaces is the maximum number of digits to be printed after the comma or full precision of the given field type if -1.

References getPCLPointAsString().

Referenced by getPCLPointAsString(), getPCLPointAsString(), getPCLPointAsString(), getPCLPointAsString(), and getPCLPointListAsString().

◆ getPCLPointAsString() [2/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPCLPointAsString ( const pcl::PointXYZINormal & point,
int numDecimalPlaces = -1 )

References getPCLPointAsString().

◆ getPCLPointAsString() [3/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPCLPointAsString ( const pcl::PointXYZLNormal & point,
int numDecimalPlaces = -1 )

References getPCLPointAsString().

◆ getPCLPointAsString() [4/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPCLPointAsString ( const pcl::PointXYZRGBNormal & point,
int numDecimalPlaces = -1 )

References getPCLPointAsString().

◆ getPCLPointListAsString()

std::string ml::PCLSupportTools::getPCLPointListAsString ( const POINT_CLOUD_TYPE & pointCloud,
MLint maxNumShownPoints = ML_INT64_MAX,
MLint indexOfFirstPoint = 0,
bool showIndices = true,
const std::string & lineSeparator = "\n",
int numDecimalPlaces = -1,
const std::string & pointsPrintFormatStr = "" )
inline

Converts at most maxNumShownPoints from pointCloud starting at position indexOfFirstPoint into a string which is separated between points with lineSeparator, each line will contain the x, y, z, and data[3] value of the corresponding point and a prefix showing the current index position of the point in pointCloud.points if showIndices is true.

If pointCloud is nullptr then an empty string will be returned.

Parameters
pointCloudThe point cloud whose points shall be printed into a string.
maxNumShownPointsThe maximum number of points to be printed, starting with indexOfFirstPoint.
indexOfFirstPointThe index of the first point from which the point list is printed.
showIndicesIf enabled then the point position and a ":" is printed as prefix before each point line, otherwise only the point position and values are printed.
lineSeparatorA string used to separate subsequent point string, usually something like a newline or so.
numDecimalPlacesThe maximum number of digits to be printed after the comma or full precision of the given field type if -1.
pointsPrintFormatStrDefault point print format is used if empty. Otherwise it can be an arbitrary string in which defined substrings are replaced with point field values if possible. For replaced substring descriptions see getPCLPointAsFormattedString(). return The string containing the printed numbers.

Definition at line 971 of file mlPCLSupportTools.h.

References getPCLPointAsFormattedString(), getPCLPointAsString(), getPCLPointListAsString(), and mlrange_cast().

Referenced by getPCLPointListAsString().

◆ getPCLVerticesAsString()

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPCLVerticesAsString ( const std::vector< pcl::Vertices > & vertices,
MLint maxNumShownVertices = ML_INT64_MAX,
MLint indexOfFirstVertex = 0,
bool showIndices = true,
const std::string & lineSeparator = _PCLSupportTools_NewLineDefaultArgumentString )

Converts at most maxNumShownVertices vertices from vertices starting at position indexOfFirstVertex into a string which is separated between points with lineSeparator, each line will contain the x, y, z, and data[3] value of the corresponding vertex and a prefix showing the current index position of the point in pointCloud.points if showIndices is true.

Parameters
verticesThe vertex vector whose vertices shall be printed into a string.
maxNumShownVerticesThe maximum number of vertices to be printed, starting with indexOfFirstVertex.
indexOfFirstVertexThe index of the first vertex from which the vertex vector is printed.
showIndicesIf enabled then the vertex position and a ":" is printed as prefix before each point line, otherwise only the vertex position and values are printed.
lineSeparatorA string used to separate subsequent point string, usually something like a newline or so. return The string containing the printed numbers.

References getPCLVerticesAsString().

Referenced by getPCLVerticesAsString().

◆ getPointFieldDataTypeString()

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPointFieldDataTypeString ( std::uint8_t fd,
bool aligned )

Returns a human readable string for a pcl::PCLPointField::PointFieldTypes enumerator.

Parameters
fdAn enumerator from pcl::PCLPointField::PointFieldTypes.
alignedIf true then all possible returned type strings are aligned to the same length, possibly filled with leading spaces; if false then all have the minimum length to returns the type string.

References getPointFieldDataTypeString().

Referenced by getPointFieldDataTypeString().

◆ getPointFieldValueAsString()

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getPointFieldValueAsString ( std::uint8_t fd,
const std::uint8_t * dataPtr,
int numDecimalPlaces = -1 )

Reinterprets the data at position dataPtr as a pcl::PointField::PointFieldTypes enumerator given by fd and converts the content to a human readable string.

Parameters
fdData type of the field pointed to by dataPtr.
dataPtrThe data structure to be interpreted as fd converted to a human readable string. dataPtr must point to a valid structure described by fd or undefined behaviour will happen.
numDecimalPlacesThe maximum number of digits to be printed after the comma or full precision of the given field type if -1.

References getPointFieldValueAsString().

Referenced by getPointFieldValueAsString().

◆ getPointNormal() [1/4]

void ml::PCLSupportTools::getPointNormal ( const pcl::PointXYZ & ,
float & nx,
float & ny,
float & nz )
inline

Returns the normal field members normal_x, normal_y, normal_z of a point p in nx, ny, nz if the point contains such members; if the point has no normal members then in nx, ny, and nz 0 is returned, for example in the case of pcl::PointXYZ.

Definition at line 754 of file mlPCLSupportTools.h.

References getPointNormal(), and mlrange_cast().

Referenced by getPointNormal(), getPointNormal(), getPointNormal(), and getPointNormal().

◆ getPointNormal() [2/4]

void ml::PCLSupportTools::getPointNormal ( const pcl::PointXYZINormal & p,
float & nx,
float & ny,
float & nz )
inline

Definition at line 772 of file mlPCLSupportTools.h.

References getPointNormal(), and mlrange_cast().

◆ getPointNormal() [3/4]

void ml::PCLSupportTools::getPointNormal ( const pcl::PointXYZLNormal & p,
float & nx,
float & ny,
float & nz )
inline

Definition at line 760 of file mlPCLSupportTools.h.

References getPointNormal(), and mlrange_cast().

◆ getPointNormal() [4/4]

void ml::PCLSupportTools::getPointNormal ( const pcl::PointXYZRGBNormal & p,
float & nx,
float & ny,
float & nz )
inline

Definition at line 766 of file mlPCLSupportTools.h.

References getPointNormal(), and mlrange_cast().

◆ getPointRGBA() [1/4]

unsigned int ml::PCLSupportTools::getPointRGBA ( const pcl::PointXYZ & )
inline

Get the rgba value from PCL point if it has that member otherwise get 0u; for set functionality set that member or do nothing otherwise.

Definition at line 681 of file mlPCLSupportTools.h.

References getPointRGBA().

Referenced by getPointRGBA(), getPointRGBA(), getPointRGBA(), and getPointRGBA().

◆ getPointRGBA() [2/4]

unsigned int ml::PCLSupportTools::getPointRGBA ( const pcl::PointXYZINormal & )
inline

Definition at line 685 of file mlPCLSupportTools.h.

References getPointRGBA().

◆ getPointRGBA() [3/4]

unsigned int ml::PCLSupportTools::getPointRGBA ( const pcl::PointXYZLNormal & )
inline

Definition at line 693 of file mlPCLSupportTools.h.

References getPointRGBA().

◆ getPointRGBA() [4/4]

unsigned int ml::PCLSupportTools::getPointRGBA ( const pcl::PointXYZRGBNormal & rgbaPnt)
inline

Definition at line 689 of file mlPCLSupportTools.h.

References getPointRGBA(), and mlrange_cast().

◆ getPointStructureT()

std::string ml::PCLSupportTools::getPointStructureT ( const POINT_CLOUD_TYPE & pointCloud)
inline

Returns an empty string if pointCloud.points are empty, otherwise a concatenated, comma separated string of string descriptions of all members of a point of this point cloud.

Definition at line 1033 of file mlPCLSupportTools.h.

References getPointStructureT(), and mlrange_cast().

Referenced by getPointStructureT().

◆ getScalarMemberNameAsString() [1/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberNameAsString ( const pcl::PointXYZ & ,
size_t memberIdx )

Return the memberIdx'th string name of scalar member p as string, regardless whether it is stored in a structure, array or as single member. Invalid indices are allowed and lead to the return of an empty string.

References getScalarMemberNameAsString().

Referenced by getScalarMemberNameAsString(), getScalarMemberNameAsString(), getScalarMemberNameAsString(), and getScalarMemberNameAsString().

◆ getScalarMemberNameAsString() [2/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberNameAsString ( const pcl::PointXYZINormal & ,
size_t memberIdx )

◆ getScalarMemberNameAsString() [3/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberNameAsString ( const pcl::PointXYZLNormal & ,
size_t memberIdx )

◆ getScalarMemberNameAsString() [4/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberNameAsString ( const pcl::PointXYZRGBNormal & ,
size_t memberIdx )

◆ getScalarMemberValueAsString() [1/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberValueAsString ( const pcl::PointXYZ & p,
size_t memberIdx,
int numDecimalPlaces = -1 )

Return the memberIdx'th scalar member of p as string, regardless of its types or whether it is stored in a structures, arrays or single member. Invalid indices are allowed and lead to the return of an empty string. numDecimalPlaces is the maximum number of digits to be printed after the comma or full precision of the given field type if -1.

References getScalarMemberValueAsString().

Referenced by getPCLPointAsFormattedString(), getScalarMemberValueAsString(), getScalarMemberValueAsString(), getScalarMemberValueAsString(), and getScalarMemberValueAsString().

◆ getScalarMemberValueAsString() [2/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberValueAsString ( const pcl::PointXYZINormal & p,
size_t memberIdx,
int numDecimalPlaces = -1 )

◆ getScalarMemberValueAsString() [3/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberValueAsString ( const pcl::PointXYZLNormal & p,
size_t memberIdx,
int numDecimalPlaces = -1 )

◆ getScalarMemberValueAsString() [4/4]

MLPCLSUPPORT_EXPORT std::string ml::PCLSupportTools::getScalarMemberValueAsString ( const pcl::PointXYZRGBNormal & p,
size_t memberIdx,
int numDecimalPlaces = -1 )

◆ getSigned32BitMaximumLimit()

MLPCLSUPPORT_EXPORT MLuint64 ml::PCLSupportTools::getSigned32BitMaximumLimit ( )

Returns the maximum number of entries allowed in data structured with 32 bit signed indexing, for example in Open Inventor MFields or some members in PCL clouds.


References getSigned32BitMaximumLimit().

Referenced by getSigned32BitMaximumLimit().

◆ getStatistics()

PointCloudStatistics ml::PCLSupportTools::getStatistics ( const POINT_CLOUD_TYPE & pointCloud,
const std::string & floatPointMemberName = "intensityReplacement",
const bool calculateMedian = false )
inline

Traverses all points in the pointCloud and returns some statistical parameters.

Parameters
pointCloudThe point cloud from whose members the statistics shall be calculated.
floatPointMemberNameThe name of the floating point member from which the statistical values shall be claculated; if no such member exists the statistical default values are returned.
calculateMedianif true then also the median value is calculated, otherwise not: requires temporary allocation of a float for each point in pointCloud and changes time requirements from O(n) to O(log(n)) if enabled.

Definition at line 69 of file mlPCLSupportStatistics.h.

References getStatistics(), ML_SIZE_T_MAX, and mlrange_cast().

Referenced by getStatistics().

◆ getUnsigned32BitMaximumLimit()

MLPCLSUPPORT_EXPORT MLuint64 ml::PCLSupportTools::getUnsigned32BitMaximumLimit ( )

Returns the maximum number of entries allowed in data structured with 32 bit unsigned indexing, for example in Open Inventor MFields or some members in PCL clouds.


References getUnsigned32BitMaximumLimit().

Referenced by getUnsigned32BitMaximumLimit().

◆ hasCurvature() [1/4]

bool ml::PCLSupportTools::hasCurvature ( const pcl::PointXYZ & )
inline

Returns true if the passed point has a curvature field, otherwise false.

Definition at line 829 of file mlPCLSupportTools.h.

References hasCurvature().

Referenced by hasCurvature(), hasCurvature(), hasCurvature(), and hasCurvature().

◆ hasCurvature() [2/4]

bool ml::PCLSupportTools::hasCurvature ( const pcl::PointXYZINormal & )
inline

Definition at line 832 of file mlPCLSupportTools.h.

References hasCurvature(), and mlrange_cast().

◆ hasCurvature() [3/4]

bool ml::PCLSupportTools::hasCurvature ( const pcl::PointXYZLNormal & )
inline

Definition at line 830 of file mlPCLSupportTools.h.

References hasCurvature(), and mlrange_cast().

◆ hasCurvature() [4/4]

bool ml::PCLSupportTools::hasCurvature ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 831 of file mlPCLSupportTools.h.

References hasCurvature(), and mlrange_cast().

◆ hasIntensity() [1/4]

bool ml::PCLSupportTools::hasIntensity ( const pcl::PointXYZ & )
inline

Returns true if the passed point has an intensity field, otherwise false.

Definition at line 818 of file mlPCLSupportTools.h.

References hasIntensity().

Referenced by getPCLPointAsFormattedString(), hasIntensity(), hasIntensity(), hasIntensity(), and hasIntensity().

◆ hasIntensity() [2/4]

bool ml::PCLSupportTools::hasIntensity ( const pcl::PointXYZINormal & )
inline

Definition at line 821 of file mlPCLSupportTools.h.

References hasIntensity(), and mlrange_cast().

◆ hasIntensity() [3/4]

bool ml::PCLSupportTools::hasIntensity ( const pcl::PointXYZLNormal & )
inline

Definition at line 819 of file mlPCLSupportTools.h.

References hasIntensity().

◆ hasIntensity() [4/4]

bool ml::PCLSupportTools::hasIntensity ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 820 of file mlPCLSupportTools.h.

References hasIntensity().

◆ hasIntensityReplacement() [1/4]

bool ml::PCLSupportTools::hasIntensityReplacement ( const pcl::PointXYZ & )
inline

Returns true if the passed point has any field which can be interpreted as an intensity replacement field, otherwise false.

Definition at line 840 of file mlPCLSupportTools.h.

References hasIntensityReplacement().

Referenced by getPCLPointAsFormattedString(), hasIntensityReplacement(), hasIntensityReplacement(), hasIntensityReplacement(), and hasIntensityReplacement().

◆ hasIntensityReplacement() [2/4]

bool ml::PCLSupportTools::hasIntensityReplacement ( const pcl::PointXYZINormal & )
inline

Definition at line 843 of file mlPCLSupportTools.h.

References hasIntensityReplacement(), and mlrange_cast().

◆ hasIntensityReplacement() [3/4]

bool ml::PCLSupportTools::hasIntensityReplacement ( const pcl::PointXYZLNormal & )
inline

Definition at line 841 of file mlPCLSupportTools.h.

References hasIntensityReplacement(), and mlrange_cast().

◆ hasIntensityReplacement() [4/4]

bool ml::PCLSupportTools::hasIntensityReplacement ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 842 of file mlPCLSupportTools.h.

References hasIntensityReplacement(), and mlrange_cast().

◆ hasLabel() [1/4]

bool ml::PCLSupportTools::hasLabel ( const pcl::PointXYZ & )
inline

Returns true if the passed point has a label field, otherwise false.

Definition at line 796 of file mlPCLSupportTools.h.

References hasLabel().

Referenced by getPCLPointAsFormattedString(), hasLabel(), hasLabel(), hasLabel(), and hasLabel().

◆ hasLabel() [2/4]

bool ml::PCLSupportTools::hasLabel ( const pcl::PointXYZINormal & )
inline

Definition at line 799 of file mlPCLSupportTools.h.

References hasLabel().

◆ hasLabel() [3/4]

bool ml::PCLSupportTools::hasLabel ( const pcl::PointXYZLNormal & )
inline

Definition at line 797 of file mlPCLSupportTools.h.

References hasLabel(), and mlrange_cast().

◆ hasLabel() [4/4]

bool ml::PCLSupportTools::hasLabel ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 798 of file mlPCLSupportTools.h.

References hasLabel().

◆ hasNormal() [1/4]

bool ml::PCLSupportTools::hasNormal ( const pcl::PointXYZ & )
inline

Returns true if the passed point has a normal, otherwise false.

Definition at line 785 of file mlPCLSupportTools.h.

References hasNormal().

Referenced by hasNormal(), hasNormal(), hasNormal(), and hasNormal().

◆ hasNormal() [2/4]

bool ml::PCLSupportTools::hasNormal ( const pcl::PointXYZINormal & )
inline

Definition at line 788 of file mlPCLSupportTools.h.

References hasNormal(), and mlrange_cast().

◆ hasNormal() [3/4]

bool ml::PCLSupportTools::hasNormal ( const pcl::PointXYZLNormal & )
inline

Definition at line 786 of file mlPCLSupportTools.h.

References hasNormal(), and mlrange_cast().

◆ hasNormal() [4/4]

bool ml::PCLSupportTools::hasNormal ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 787 of file mlPCLSupportTools.h.

References hasNormal(), and mlrange_cast().

◆ hasNormals() [1/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZ & )
inline

Definition at line 119 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [2/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZINormal & )
inline

Definition at line 128 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [3/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZINormalPtr & )
inline

Definition at line 129 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [4/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZLNormal & )
inline

Definition at line 122 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [5/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZLNormalPtr & )
inline

Definition at line 123 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [6/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZPtr & )
inline

Definition at line 120 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [7/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZRGBNormal & )
inline

Definition at line 125 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [8/12]

bool ml::PCLSupportTools::hasNormals ( const MLPointCloudXYZRGBNormalPtr & )
inline

Definition at line 126 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [9/12]

bool ml::PCLSupportTools::hasNormals ( const pcl::PointXYZ & )
inline

Returns true if the point or point type contains normal fields/members, otherwise false,.

Definition at line 118 of file mlPCLSupportTools.h.

References hasNormals().

Referenced by hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), hasNormals(), and hasNormals().

◆ hasNormals() [10/12]

bool ml::PCLSupportTools::hasNormals ( const pcl::PointXYZINormal & )
inline

Definition at line 127 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [11/12]

bool ml::PCLSupportTools::hasNormals ( const pcl::PointXYZLNormal & )
inline

Definition at line 121 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasNormals() [12/12]

bool ml::PCLSupportTools::hasNormals ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 124 of file mlPCLSupportTools.h.

References hasNormals().

◆ hasRGBA() [1/4]

bool ml::PCLSupportTools::hasRGBA ( const pcl::PointXYZ & )
inline

Returns true if the passed point has an rgba field, otherwise false.

Definition at line 807 of file mlPCLSupportTools.h.

References hasRGBA().

Referenced by getPCLPointAsFormattedString(), hasRGBA(), hasRGBA(), hasRGBA(), and hasRGBA().

◆ hasRGBA() [2/4]

bool ml::PCLSupportTools::hasRGBA ( const pcl::PointXYZINormal & )
inline

Definition at line 810 of file mlPCLSupportTools.h.

References hasRGBA().

◆ hasRGBA() [3/4]

bool ml::PCLSupportTools::hasRGBA ( const pcl::PointXYZLNormal & )
inline

Definition at line 808 of file mlPCLSupportTools.h.

References hasRGBA().

◆ hasRGBA() [4/4]

bool ml::PCLSupportTools::hasRGBA ( const pcl::PointXYZRGBNormal & )
inline

Definition at line 809 of file mlPCLSupportTools.h.

References hasRGBA(), and mlrange_cast().

◆ PCLExtractSubIndices()

MLPCLSUPPORT_EXPORT void ml::PCLSupportTools::PCLExtractSubIndices ( const std::vector< int > & subIndices,
std::vector< int > & indices )

Extract all indices from indices if they are listed in subIndices in the order as given in subIndices; indices out of range in subIndices are ignored.

The result index set is returned by modifying indices inplace.

Parameters
subIndicesVector of indices to extract from indices.
indicesIncoming vector of indices from which one a subset shall be returned inplace.

References PCLExtractSubIndices().

Referenced by PCLExtractSubIndices().

◆ setCurvature() [1/4]

void ml::PCLSupportTools::setCurvature ( pcl::PointXYZ & ,
float  )
inline

Definition at line 654 of file mlPCLSupportTools.h.

References setCurvature().

Referenced by setCurvature(), setCurvature(), setCurvature(), and setCurvature().

◆ setCurvature() [2/4]

void ml::PCLSupportTools::setCurvature ( pcl::PointXYZINormal & p,
float curvature )
inline

Definition at line 666 of file mlPCLSupportTools.h.

References mlrange_cast(), and setCurvature().

◆ setCurvature() [3/4]

void ml::PCLSupportTools::setCurvature ( pcl::PointXYZLNormal & p,
float curvature )
inline

Definition at line 658 of file mlPCLSupportTools.h.

References mlrange_cast(), and setCurvature().

◆ setCurvature() [4/4]

void ml::PCLSupportTools::setCurvature ( pcl::PointXYZRGBNormal & p,
float curvature )
inline

Definition at line 662 of file mlPCLSupportTools.h.

References mlrange_cast(), and setCurvature().

◆ setFieldsFromPoint() [1/4]

void ml::PCLSupportTools::setFieldsFromPoint ( const pcl::PointXYZ & pnt,
std::vector< DoubleField * > & resultFields )
inline

Set resultFields to the corresponding member states of pnt; the resultFields vector must have a sufficient size for all members of the point cloud points, accesses out-of range are not handled.

Definition at line 281 of file mlPCLSupportTools.h.

References mlrange_cast(), and setFieldsFromPoint().

Referenced by setFieldsFromPoint(), setFieldsFromPoint(), setFieldsFromPoint(), and setFieldsFromPoint().

◆ setFieldsFromPoint() [2/4]

void ml::PCLSupportTools::setFieldsFromPoint ( const pcl::PointXYZINormal & pnt,
std::vector< DoubleField * > & resultFields )
inline

Definition at line 314 of file mlPCLSupportTools.h.

References mlrange_cast(), and setFieldsFromPoint().

◆ setFieldsFromPoint() [3/4]

void ml::PCLSupportTools::setFieldsFromPoint ( const pcl::PointXYZLNormal & pnt,
std::vector< DoubleField * > & resultFields )
inline

Definition at line 288 of file mlPCLSupportTools.h.

References mlrange_cast(), and setFieldsFromPoint().

◆ setFieldsFromPoint() [4/4]

void ml::PCLSupportTools::setFieldsFromPoint ( const pcl::PointXYZRGBNormal & pnt,
std::vector< DoubleField * > & resultFields )
inline

Definition at line 301 of file mlPCLSupportTools.h.

References mlrange_cast(), and setFieldsFromPoint().

◆ setIntensityReplacement() [1/4]

void ml::PCLSupportTools::setIntensityReplacement ( pcl::PointXYZ & ,
float = 1.f,
MLuint8 = 0xff )
inline

Sets a scalar value in a member which can be used as storage for an additional value, such as the curvature in a pcl::PointXYZLNormal or in RGB members.

If the point has no such member then the value is lost, for example in the case of pcl::PointXYZ. In case of INormals, and LNormals the curvature is set, in the case of RGBNormal values curvature and RGBA will be set; curvature will directly be set to value, r, g, b to 255.9999f*value and alpha to the provided opacity the value which defaults to 0xff which is opaque. opacity is unused in cases of INormal, XYZ, and LNormal points.

Definition at line 585 of file mlPCLSupportTools.h.

References setIntensityReplacement().

Referenced by setIntensityReplacement(), setIntensityReplacement(), setIntensityReplacement(), and setIntensityReplacement().

◆ setIntensityReplacement() [2/4]

void ml::PCLSupportTools::setIntensityReplacement ( pcl::PointXYZINormal & p,
float value = 1.f,
MLuint8 = 0xff )
inline

Definition at line 599 of file mlPCLSupportTools.h.

References setIntensityReplacement().

◆ setIntensityReplacement() [3/4]

void ml::PCLSupportTools::setIntensityReplacement ( pcl::PointXYZLNormal & p,
float value = 1.f,
MLuint8 = 0xff )
inline

Definition at line 589 of file mlPCLSupportTools.h.

References setIntensityReplacement().

◆ setIntensityReplacement() [4/4]

void ml::PCLSupportTools::setIntensityReplacement ( pcl::PointXYZRGBNormal & p,
float value = 1.f,
MLuint8 opacity = 0xff )
inline

Definition at line 593 of file mlPCLSupportTools.h.

References mlrange_cast(), and setIntensityReplacement().

◆ setPointFromFields() [1/4]

void ml::PCLSupportTools::setPointFromFields ( pcl::PointXYZ & pnt,
const std::vector< DoubleField * > & constantFields )
inline

Copy states of constantFields to the corresponding member of pnt; the contantFields vector must have a sufficient size for all members of the point cloud points, accesses out-of range are not handled.

Value assignments of negative floats to unsigned integers (for example to the label) are performed as cast from absolute floats to have a defined operation.

Definition at line 171 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointFromFields().

Referenced by setPointFromFields(), setPointFromFields(), setPointFromFields(), and setPointFromFields().

◆ setPointFromFields() [2/4]

void ml::PCLSupportTools::setPointFromFields ( pcl::PointXYZINormal & pnt,
const std::vector< DoubleField * > & constantFields )
inline

Definition at line 204 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointFromFields().

◆ setPointFromFields() [3/4]

void ml::PCLSupportTools::setPointFromFields ( pcl::PointXYZLNormal & pnt,
const std::vector< DoubleField * > & constantFields )
inline

Definition at line 178 of file mlPCLSupportTools.h.

References MLAbs(), mlrange_cast(), and setPointFromFields().

◆ setPointFromFields() [4/4]

void ml::PCLSupportTools::setPointFromFields ( pcl::PointXYZRGBNormal & pnt,
const std::vector< DoubleField * > & constantFields )
inline

Definition at line 191 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointFromFields().

◆ setPointFromScalar() [1/4]

void ml::PCLSupportTools::setPointFromScalar ( pcl::PointXYZ & pnt,
const float val )
inline

Copy a scalar value into all point fields.

Value assignments of negative floats to unsigned integers (for example to the label) are performed as cast from absolute floats to have a defined operation.

Definition at line 226 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointFromScalar().

Referenced by setPointFromScalar(), setPointFromScalar(), setPointFromScalar(), and setPointFromScalar().

◆ setPointFromScalar() [2/4]

void ml::PCLSupportTools::setPointFromScalar ( pcl::PointXYZINormal & pnt,
const float val )
inline

Definition at line 259 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointFromScalar().

◆ setPointFromScalar() [3/4]

void ml::PCLSupportTools::setPointFromScalar ( pcl::PointXYZLNormal & pnt,
const float val )
inline

Definition at line 233 of file mlPCLSupportTools.h.

References MLAbs(), mlrange_cast(), and setPointFromScalar().

◆ setPointFromScalar() [4/4]

void ml::PCLSupportTools::setPointFromScalar ( pcl::PointXYZRGBNormal & pnt,
const float val )
inline

Definition at line 246 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointFromScalar().

◆ setPointNormal() [1/4]

void ml::PCLSupportTools::setPointNormal ( pcl::PointXYZ & ,
float ,
float ,
float  )
inline

Sets the normal fields normal_x, normal_y, normal_z of a point from nx, ny, nz if the point contains such members; if the point has no normal members then the call is ignored, for example in the case of pcl::PointXYZ.

Definition at line 723 of file mlPCLSupportTools.h.

References setPointNormal().

Referenced by setPointNormal(), setPointNormal(), setPointNormal(), and setPointNormal().

◆ setPointNormal() [2/4]

void ml::PCLSupportTools::setPointNormal ( pcl::PointXYZINormal & p,
float nx,
float ny,
float nz )
inline

Definition at line 739 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointNormal().

◆ setPointNormal() [3/4]

void ml::PCLSupportTools::setPointNormal ( pcl::PointXYZLNormal & p,
float nx,
float ny,
float nz )
inline

Definition at line 727 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointNormal().

◆ setPointNormal() [4/4]

void ml::PCLSupportTools::setPointNormal ( pcl::PointXYZRGBNormal & p,
float nx,
float ny,
float nz )
inline

Definition at line 733 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointNormal().

◆ setPointRGBA() [1/4]

void ml::PCLSupportTools::setPointRGBA ( pcl::PointXYZ & ,
MLuint32  )
inline

Definition at line 697 of file mlPCLSupportTools.h.

References setPointRGBA().

Referenced by setPointRGBA(), setPointRGBA(), setPointRGBA(), and setPointRGBA().

◆ setPointRGBA() [2/4]

void ml::PCLSupportTools::setPointRGBA ( pcl::PointXYZINormal & ,
MLuint32  )
inline

Definition at line 701 of file mlPCLSupportTools.h.

References setPointRGBA().

◆ setPointRGBA() [3/4]

void ml::PCLSupportTools::setPointRGBA ( pcl::PointXYZLNormal & ,
MLuint32  )
inline

Definition at line 710 of file mlPCLSupportTools.h.

References setPointRGBA().

◆ setPointRGBA() [4/4]

void ml::PCLSupportTools::setPointRGBA ( pcl::PointXYZRGBNormal & rgbaPnt,
MLuint32 srcVal )
inline

Definition at line 705 of file mlPCLSupportTools.h.

References mlrange_cast(), and setPointRGBA().

Variable Documentation

◆ FloatPointMemberNames

MLPCLSUPPORT_EXPORT const char* const ml::PCLSupportTools::FloatPointMemberNames[ML_PCL_NUMBER_OF_FLOAT_POINT_MEMBER_NAMES]
extern

Number of possible float members as strings which might appear in current implementation.

◆ PointMemberNames

MLPCLSUPPORT_EXPORT const char* const ml::PCLSupportTools::PointMemberNames[ML_PCL_NUMBER_OF_POINT_MEMBER_NAMES]
extern

Possible members of points as strings which might appear in current implementation.