SimplePointWriter handles some of the bookkeeping of writing a file.
More...
#include <SimplePointWriter.h>
|
| void | setQuantization (const double scale[3], const double offset[3]) |
| | Set the quantization. More...
|
| |
| const double * | getScale (void) const |
| | Get the quantization scale. More...
|
| |
| const double * | getOffset (void) const |
| | Get the quantization offset. More...
|
| |
| count_type | write (const Bounds &bounds, double fraction, const PointInfo &pointInfo, ProgressDelegate *delegate) |
| |
| virtual void | writeBegin (const PointInfo &pointInfo)=0 |
| | Begin writing the file. More...
|
| |
| virtual void | writePoints (const PointData &points, size_t numPoints, ProgressDelegate *delegate)=0 |
| | Write a set of points. More...
|
| |
| virtual void | writeEnd (PointSource::count_type numPoints, const Bounds &bounds)=0 |
| | Finish writing the file. More...
|
| |
| void | setMetadata (const Metadata &metadata) |
| | Set the metadata. More...
|
| |
| Metadata & | getMetadata (void) |
| | Get the Metadata. More...
|
| |
| virtual void | setQuantization (const double scale[3], const double offset[3])=0 |
| | Set the quantization. More...
|
| |
| virtual const double * | getScale (void) const =0 |
| | Get the quantization scale. More...
|
| |
| virtual const double * | getOffset (void) const =0 |
| | Get the quantization offset. More...
|
| |
| virtual count_type | write (const Bounds &bounds, double fraction, const PointInfo &pointInfo, ProgressDelegate *delegate)=0 |
| | Write out the point cloud. More...
|
| |
| void | setChunckSize (size_t size) |
| |
| virtual bool | supportedChannels (const PointInfo &inputPointInfo, PointInfo &supportedPointInfo) const =0 |
| | Remove the unsupported channels. More...
|
| |
| int | retain (void) const |
| | Increment the reference count by one. More...
|
| |
| int | release (void) const |
| | Decrement the reference count by one. More...
|
| |
Definition at line 18 of file SimplePointWriter.h.
◆ getOffset()
| const double * SimplePointWriter::getOffset |
( |
void |
| ) |
const |
|
virtual |
This method returns the quantization offset for X, Y, and Z channels. It returns nullptr then the point cloud is not quantized or quantization is unknown.
- Note
- By default this will be the same as the PointSources' offset.
Implements PointWriter.
◆ getScale()
| const double * SimplePointWriter::getScale |
( |
void |
| ) |
const |
|
virtual |
This method returns the quantization scale factors for X, Y, and Z channels. It returns nullptr then the point cloud is not quantized or quantization is unknown.
- Note
- By default this will be the same as the PointSources' scale.
Implements PointWriter.
◆ getTotalWork()
| virtual double SimplePointWriter::getTotalWork |
( |
const Bounds & |
bounds, |
|
|
double |
fraction |
|
) |
| const |
|
protectedvirtual |
This method returns the work needed to wirte the file.
- Parameters
-
| bounds | the region of interest (HUGE_VAL are handled) |
| fraction | the fraction of the points you want (use 1.0 for all the points and use 0.1 to keep every tenth point) |
- Note
- This value does not include the work needed to read the source points.
◆ setQuantization()
| void SimplePointWriter::setQuantization |
( |
const double |
scale[3], |
|
|
const double |
offset[3] |
|
) |
| |
|
virtual |
This method set the output files quantization values.
- Parameters
-
| scale | the quantization scale factor (may be nullptr) |
| offset | the quantization offset (may be nullptr) |
- Note
- Some file format requier quantization, so make sure you call this if needed.
-
The default values are the input PointSource values.
Implements PointWriter.
◆ write()
◆ writeBegin()
| virtual void SimplePointWriter::writeBegin |
( |
const PointInfo & |
pointInfo | ) |
|
|
pure virtual |
This method is called to start writing file.
- Parameters
-
| channelInfo | an array describing which channels are being saved |
| numChannels | the number of channels |
Implemented in TXTPointWriter.
◆ writeEnd()
This method is called when no more points are left.
- Parameters
-
| numPoints | the total number of points written |
| bounds | the tight boundsing box the points |
- Note
- On faliure writeEnd() is called with numPoints = 0 and bounds = Bounds::Huge()
Implemented in TXTPointWriter.
◆ writePoints()
This method is called when points need to be written.
- Parameters
-
| points | the points to be written |
| numPoints | the number of points to write |
| delegete | the progress delegete to be updated (can be nullptr) |
Implemented in TXTPointWriter.
◆ m_offsets
| double SimplePointWriter::m_offsets[3] |
|
protected |
◆ m_scale
| double SimplePointWriter::m_scale[3] |
|
protected |
The documentation for this class was generated from the following file: