![]() |
ACloudViewer
3.9.4
A Modern Library for 3D Data Processing
|
#include <CVPointCloud.h>


Public Member Functions | |
| PointCloud ()=default | |
| Default constructor. More... | |
| ~PointCloud () override=default | |
| Default destructor. More... | |
| bool | reserveNormals (unsigned newCount) |
| Reserves memory to store the normals. More... | |
| bool | resize (unsigned newCount) override |
| Resizes the point database. More... | |
| void | addNormal (const CCVector3 &N) |
| Adds a normal. More... | |
| std::vector< CCVector3 > & | normals () |
| Returns the set of normals. More... | |
| const std::vector< CCVector3 > & | normals () const |
| Returns the set of normals (const version) More... | |
| bool | normalsAvailable () const override |
| Returns whether normals are available. More... | |
| const CCVector3 * | getNormal (unsigned pointIndex) const override |
| If per-point normals are available, returns the one at a specific index. More... | |
Public Member Functions inherited from cloudViewer::PointCloudTpl< GenericIndexedCloudPersist > | |
| PointCloudTpl () | |
| Default constructor. More... | |
| virtual | ~PointCloudTpl () |
| Default destructor. More... | |
| unsigned | size () const override |
| void | forEach (GenericCloud::genericPointAction action) override |
| void | getBoundingBox (CCVector3 &bbMin, CCVector3 &bbMax) override |
| void | placeIteratorAtBeginning () override |
| const CCVector3 * | getNextPoint () override |
| bool | enableScalarField () override |
| bool | isScalarFieldEnabled () const override |
| void | setPointScalarValue (unsigned pointIndex, ScalarType value) override |
| ScalarType | getPointScalarValue (unsigned pointIndex) const override |
| const CCVector3 * | getPoint (unsigned index) const override |
| void | getPoint (unsigned index, CCVector3 &P) const override |
| void | getPoint (unsigned index, double P[3]) const override |
| CCVector3 * | getPointPtr (size_t index) |
| std::vector< CCVector3 > & | getPoints () |
| const std::vector< CCVector3 > & | getPoints () const |
| const CCVector3 * | getPointPersistentPtr (unsigned index) override |
| const CCVector3 * | getPointPersistentPtr (unsigned index) const |
| virtual bool | reserve (unsigned newCapacity) |
| Reserves memory for the point database. More... | |
| void | reset () |
| Clears the cloud database. More... | |
| void | addPoint (const CCVector3 &P) |
| Adds a 3D point to the database. More... | |
| void | addPoint (double x, double y, double z) |
| void | addPoint (double xyz[3]) |
| void | setPoint (size_t index, const CCVector3 &P) |
| void | setEigenPoint (size_t index, const Eigen::Vector3d &point) |
| void | addEigenPoint (const Eigen::Vector3d &point) |
| void | addPoints (const std::vector< CCVector3 > &points) |
| void | addPoints (const std::vector< Eigen::Vector3d > &points) |
| Eigen::Vector3d | getEigenPoint (size_t index) const |
| std::vector< Eigen::Vector3d > | getEigenPoints () const |
| void | setEigenPoints (const std::vector< Eigen::Vector3d > &points) |
| virtual void | invalidateBoundingBox () |
| Invalidates bounding box. More... | |
| unsigned | getNumberOfScalarFields () const |
| Returns the number of associated (and active) scalar fields. More... | |
| ScalarField * | getScalarField (int index) const |
| Returns a pointer to a specific scalar field. More... | |
| const char * | getScalarFieldName (int index) const |
| Returns the name of a specific scalar field. More... | |
| int | getScalarFieldIndexByName (const char *name) const |
| Returns the index of a scalar field represented by its name. More... | |
| ScalarField * | getCurrentInScalarField () const |
| Returns the scalar field currently associated to the cloud input. More... | |
| ScalarField * | getCurrentOutScalarField () const |
| Returns the scalar field currently associated to the cloud output. More... | |
| void | setCurrentInScalarField (int index) |
| Sets the INPUT scalar field. More... | |
| int | getCurrentInScalarFieldIndex () |
| Returns current INPUT scalar field index (or -1 if none) More... | |
| void | setCurrentOutScalarField (int index) |
| Sets the OUTPUT scalar field. More... | |
| int | getCurrentOutScalarFieldIndex () |
| Returns current OUTPUT scalar field index (or -1 if none) More... | |
| void | setCurrentScalarField (int index) |
| Sets both the INPUT & OUTPUT scalar field. More... | |
| virtual int | addScalarField (const char *uniqueName) |
| Creates a new scalar field and registers it. More... | |
| bool | renameScalarField (int index, const char *newName) |
| Renames a specific scalar field. More... | |
| virtual void | deleteScalarField (int index) |
| Deletes a specific scalar field. More... | |
| virtual void | deleteAllScalarFields () |
| Deletes all scalar fields associated to this cloud. More... | |
| unsigned | capacity () const |
| Returns cloud capacity (i.e. reserved size) More... | |
Public Member Functions inherited from cloudViewer::GenericIndexedCloudPersist | |
| ~GenericIndexedCloudPersist () override=default | |
| Default destructor. More... | |
Public Member Functions inherited from cloudViewer::GenericIndexedCloud | |
| ~GenericIndexedCloud () override=default | |
| Default destructor. More... | |
Public Member Functions inherited from cloudViewer::GenericCloud | |
| GenericCloud ()=default | |
| Default constructor. More... | |
| virtual | ~GenericCloud ()=default |
| Default destructor. More... | |
| virtual bool | hasPoints () const |
| virtual unsigned char | testVisibility (const CCVector3 &P) const |
Protected Attributes | |
| std::vector< CCVector3 > | m_normals |
| Point normals (if any) More... | |
Protected Attributes inherited from cloudViewer::PointCloudTpl< GenericIndexedCloudPersist > | |
| std::vector< CCVector3 > | m_points |
| 3D Points database More... | |
| BoundingBox | m_bbox |
| Bounding-box. More... | |
| unsigned | m_currentPointIndex |
| 'Iterator' on the points db More... | |
| std::vector< ScalarField * > | m_scalarFields |
| Associated scalar fields. More... | |
| int | m_currentInScalarFieldIndex |
| Index of current scalar field used for input. More... | |
| int | m_currentOutScalarFieldIndex |
| Index of current scalar field used for output. More... | |
Additional Inherited Members | |
Public Types inherited from cloudViewer::GenericCloud | |
| using | genericPointAction = std::function< void(const CCVector3 &, ScalarType &)> |
| Generic function applied to a point (used by foreach) More... | |
Protected Member Functions inherited from cloudViewer::PointCloudTpl< GenericIndexedCloudPersist > | |
| virtual void | swapPoints (unsigned firstIndex, unsigned secondIndex) |
| Swaps two points (and their associated scalar values!) More... | |
| CCVector3 * | point (unsigned index) |
| Returns non const access to a given point. More... | |
| const CCVector3 * | point (unsigned index) const |
| Returns const access to a given point. More... | |
A storage-efficient point cloud structure that can also handle an unlimited number of scalar fields
Definition at line 18 of file CVPointCloud.h.
|
default |
Default constructor.
|
overridedefault |
Default destructor.
|
inline |
Adds a normal.
| N | a 3D normal |
Definition at line 61 of file CVPointCloud.h.
Referenced by cloudViewer::PointProjectionTools::applyTransformation().
|
inlineoverridevirtual |
If per-point normals are available, returns the one at a specific index.
Reimplemented from cloudViewer::GenericIndexedCloud.
Definition at line 76 of file CVPointCloud.h.
|
inline |
Returns the set of normals.
Definition at line 67 of file CVPointCloud.h.
|
inline |
Returns the set of normals (const version)
Definition at line 70 of file CVPointCloud.h.
|
inlineoverridevirtual |
Returns whether normals are available.
Reimplemented from cloudViewer::GenericIndexedCloud.
Definition at line 73 of file CVPointCloud.h.
References size.
|
inline |
Reserves memory to store the normals.
Definition at line 28 of file CVPointCloud.h.
Referenced by cloudViewer::PointProjectionTools::applyTransformation().
|
inlineoverridevirtual |
Resizes the point database.
The cloud database is resized with the specified size. If the new size is smaller, the overflooding points will be deleted. If its greater, the database is filled with blank points (warning, the PointCloud::addPoint method will insert points after those ones).
| newNumberOfPoints | the new number of points |
Reimplemented from cloudViewer::PointCloudTpl< GenericIndexedCloudPersist >.
Definition at line 41 of file CVPointCloud.h.
Referenced by cloudViewer::FPCSRegistrationTools::FilterCandidates(), ImportSourceVertices(), MergeOldTriangles(), cloudViewer::ICPRegistrationTools::Register(), cloudViewer::MeshSamplingTools::samplePointsOnMesh(), and cloudViewer::ManualSegmentationTools::segmentMeshWithAABox().
|
protected |
Point normals (if any)
Definition at line 82 of file CVPointCloud.h.