CVBpy 14.0
PointCloudFactory Class Reference

Factory object for creating point cloud objects. More...

Inherits object.

Public Member Functions

Union[cvb.PointCloud, cvb.DensePointCloud, cvb.SparsePointCloudcreate (cvb.ImagePlane range_map, cvb.Calibrator3D calibrator, int flags, Optional[Type[cvb.PointCloud|cvb.DensePointCloud|cvb.SparsePointCloud]] point_cloud_type=cvb.DensePointCloud)
 Creates a new Cartesian 3D point cloud from the given 2.5D range map image. More...
 
cvb.DensePointCloud create_dense (cvb.ImagePlane range_map, cvb.Calibrator3D calibrator, int flags)
 Creates a new dense Cartesian 3D point cloud from the given 2.5D range map image. More...
 
cvb.DensePointCloud create_dense_from_range_map (cvb.ImagePlane range_map, Union[cvb.Factors3D, List[float]] factors, int flags)
 Creates a new Cartesian 3D point cloud from the given 2.5D range map image. More...
 
cvb.DensePointCloud create_dense_from_size (cvb.Size2D size, int flags)
 Creates a new dense Cartesian 3D point cloud. More...
 
cvb.SparsePointCloud create_sparse (int num_points, int flags)
 Creates a new sparse Cartesian 3D point cloud. More...
 
cvb.SparsePointCloud create_sparse_from_buffer (Any buffer, int layout=cvb.PointCloudLayout.Interleaved)
 Creates a new sparse Cartesian 3D point cloud from a python buffer. More...
 
Union[cvb.DensePointCloud, cvb.SparsePointCloudcreate_with_settings (cvb.ImagePlane range_map, cvb.Calibrator3D calibrator, int flags, cvb.SensorSettings settings, float encoder_step, Optional[Type[cvb.DensePointCloud|cvb.SparsePointCloud]] point_cloud_type=cvb.DensePointCloud)
 Creates a new Cartesian 3D point cloud from the given 2.5D range map image with modified camera settings. More...
 
Union[cvb.DensePointCloud, cvb.SparsePointCloudload (str file_name, int flags)
 Loads a 3D point, polygon or mesh file. More...
 

Detailed Description

Factory object for creating point cloud objects.

Member Function Documentation

◆ create()

Union[cvb.PointCloud, cvb.DensePointCloud, cvb.SparsePointCloud] create ( cvb.ImagePlane  range_map,
cvb.Calibrator3D  calibrator,
int  flags,
Optional[Type[cvb.PointCloud| cvb.DensePointCloud| cvb.SparsePointCloud]]   point_cloud_type = cvb.DensePointCloud 
)

Creates a new Cartesian 3D point cloud from the given 2.5D range map image.

Parameters

range_map : cvb.ImagePlane Handle of 2.5D image.

calibrator : cvb.Calibrator3D Calibration object to apply.

flags : int Flags specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

point_cloud_type : Optional[Type[cvb.PointCloud| cvb.DensePointCloud| cvb.SparsePointCloud]] The point cloud type of the object to be returned.

Returns

Union[cvb.PointCloud, cvb.DensePointCloud, cvb.SparsePointCloud] A typed point cloud based on the given point_cloud_type.

◆ create_dense()

cvb.DensePointCloud create_dense ( cvb.ImagePlane  range_map,
cvb.Calibrator3D  calibrator,
int  flags 
)

Creates a new dense Cartesian 3D point cloud from the given 2.5D range map image.

Parameters

range_map : cvb.ImagePlane Handle of 2.5D image.

calibrator : cvb.Calibrator3D Calibration object to apply.

flags : int Flags specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

Returns

cvb.DensePointCloud A point cloud object.

◆ create_dense_from_range_map()

cvb.DensePointCloud create_dense_from_range_map ( cvb.ImagePlane  range_map,
Union[cvb.Factors3D, List[float]]  factors,
int  flags 
)

Creates a new Cartesian 3D point cloud from the given 2.5D range map image.

Parameters

range_map : cvb.ImagePlane 2.5D image.

factors : Union[cvb.Factors3D, List[float]] Factors to apply.

flags : int Specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

Returns

cvb.DensePointCloud A dense point cloud object.

◆ create_dense_from_size()

cvb.DensePointCloud create_dense_from_size ( cvb.Size2D  size,
int  flags 
)

Creates a new dense Cartesian 3D point cloud.

The resulting point cloud will always have a contiguous point array.Creating the point cloud with with cvb.PointCloudFlags.XYZConfidence will provideinterleaved XYZConfidence(PointCloudLayout will be Linear),whereas creating it with cvb.PointCloudFlags.WithConfidence, only XYZ will beinterleaved but not the confidence plane(PointCloudLayout will be Interleaved).

Parameters

size : cvb.Size2D Number of Cartesian X, Y, Z(, W) points on the x/y-component of the lattice.

flags : int Specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

Returns

cvb.DensePointCloud A dense point cloud object.

◆ create_sparse()

cvb.SparsePointCloud create_sparse ( int  num_points,
int  flags 
)

Creates a new sparse Cartesian 3D point cloud.

The resulting point cloud will always have a contiguous point array.Creating the point cloud with with cvb.PointCloudFlags.XYZConfidence will provideinterleaved XYZConfidence(PointCloudLayout will be Linear),whereas creating it with cvb.PointCloudFlags.WithConfidence, only XYZ will beinterleaved but not the confidence plane(PointCloudLayout will be Interleaved).

Parameters

num_points : int Number of Cartesian X, Y, Z(, W) points.

flags : int Specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

Returns

cvb.SparsePointCloud A sparse point cloud object.

◆ create_sparse_from_buffer()

cvb.SparsePointCloud create_sparse_from_buffer ( Any  buffer,
int   layout = cvb.PointCloudLayout.Interleaved 
)

Creates a new sparse Cartesian 3D point cloud from a python buffer.

Currently only single precision (float) data type is supported. Also currently number of planes must be 3.

Parameters

buffer : Any Python buffer that supports the buffer protocol.

layout : int A point cloud point layout (see cvb.PointCloudLayout).

Returns

cvb.SparsePointCloud A sparse point cloud object.

◆ create_with_settings()

Union[cvb.DensePointCloud, cvb.SparsePointCloud] create_with_settings ( cvb.ImagePlane  range_map,
cvb.Calibrator3D  calibrator,
int  flags,
cvb.SensorSettings  settings,
float  encoder_step,
Optional[Type[cvb.DensePointCloud| cvb.SparsePointCloud]]   point_cloud_type = cvb.DensePointCloud 
)

Creates a new Cartesian 3D point cloud from the given 2.5D range map image with modified camera settings.

The point cloud will automatically be converted to the given type.

Parameters

range_map : cvb.ImagePlane Handle of 2.5D image plane.

calibrator : cvb.Calibrator3D Calibration object to apply.

flags : int Flags specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

settings : cvb.SensorSettings Sensor settings applied during the acquisition of the range map.

encoder_step : float Encoder step.

point_cloud_type : Optional[Type[cvb.DensePointCloud| cvb.SparsePointCloud]] The point cloud type of the object to be returned.

Returns

Union[cvb.DensePointCloud, cvb.SparsePointCloud] A typed point cloud based on the given point_cloud_type.

◆ load()

Union[cvb.DensePointCloud, cvb.SparsePointCloud] load ( str  file_name,
int  flags 
)

Loads a 3D point, polygon or mesh file.

Parameters

file_name : str Complete path to the file to load.

flags : int Specifying the kind of point cloud to be created (see cvb.PointCloudFlags).

Returns

Union[cvb.DensePointCloud, cvb.SparsePointCloud] A point cloud object.