Public Member Functions |
| PPMWriter () |
void | setMaxZ (const float &max) |
| Sets the maximum Z value for the color gradient.
|
void | setMinZ (const float &min) |
| Sets the minimum Z value for the color gradient.
|
int | writeDepth (const std::string &file_name, const pcl::PointCloud< pcl::PointXYZRGB > &cloud) |
| Writes the depth information of a point cloud to an ASCII formated .ppm 2D color image.
|
int | writeDepthLinear (const std::string &file_name, const pcl::PointCloud< pcl::PointXYZRGB > &cloud) |
int | writeRGB (const std::string &file_name, const pcl::PointCloud< pcl::PointXYZRGB > &cloud) |
| Writes the color information of a point cloud to an ASCII formated .ppm 2D image.
|
| ~PPMWriter () |
Public Attributes |
bool | fixed_max_ |
| Flag whether a max value was defined manually.
|
bool | fixed_min_ |
| Flag whether a min value was defined manually.
|
float | max_z_ |
| Holds the maximum Z value.
|
float | min_z_ |
| Holds the minimum Z value.
|
2D image PPM file format writer.
Definition at line 96 of file io.h.
Writes the depth information of a point cloud to an ASCII formated .ppm 2D color image.
The Z values of the point cloud are encoded as a color gradient with the minimum value defined by setMinZ as RGB(255,0,0) and the maximum value defined by setMaxZ as RGB(0,0,255). If no values are defined, the minimum and maximum values of the point cloud are determined automatically.
- Parameters:
-
[in] | file_name | the output .ppm filename |
[in] | cloud | the input organized point cloud |
- Returns:
- < 0 (-1) on error, else 0
Definition at line 296 of file io.cpp.