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


Public Member Functions | |
| ccWaveform (uint8_t descriptorID=0) | |
| Default constructor. More... | |
| ~ccWaveform () override=default | |
| Destructor. More... | |
| uint8_t | descriptorID () const |
| Returns the associated descriptor (ID) More... | |
| void | setDescriptorID (uint8_t id) |
| Sets the associated descriptor (ID) More... | |
| void | setDataDescription (uint64_t dataOffset, uint32_t byteCount) |
| Describes the waveform data. More... | |
| uint32_t | getRawSample (uint32_t i, const WaveformDescriptor &descriptor, const uint8_t *dataStorage) const |
| Returns the (raw) value of a given sample. More... | |
| double | getSample (uint32_t i, const WaveformDescriptor &descriptor, const uint8_t *dataStorage) const |
| Returns the (real) value of a given sample (in volts) More... | |
| double | getRange (double &minVal, double &maxVal, const WaveformDescriptor &descriptor, const uint8_t *dataStorage) const |
| Returns the range of (real) samples. More... | |
| bool | decodeSamples (std::vector< double > &values, const WaveformDescriptor &descriptor, const uint8_t *dataStorage) const |
| Decodes the samples and store them in a vector. More... | |
| bool | toASCII (const QString &filename, const WaveformDescriptor &descriptor, const uint8_t *dataStorage) const |
| Exports (real) samples to an ASCII file. More... | |
| CCVector3 | getSamplePos (float i, const CCVector3 &P0, const WaveformDescriptor &descriptor) const |
| Returns the sample position in 3D. More... | |
| uint32_t | byteCount () const |
| Returns the number of allocated bytes. More... | |
| uint64_t | dataOffset () const |
| Returns the byte offset to waveform data. More... | |
| void | setDataOffset (uint64_t offset) |
| Sets the byte offset to waveform data. More... | |
| const uint8_t * | data (const uint8_t *dataStorage) const |
| Gives access to the internal data. More... | |
| void | setBeamDir (const CCVector3f &dir) |
| Sets the beam direction. More... | |
| const CCVector3f & | beamDir () const |
| Returns the beam direction. More... | |
| void | setEchoTime_ps (float time_ps) |
| Set the echo time (in picoseconds) More... | |
| float | echoTime_ps () const |
| Returns the echo time (in picoseconds) More... | |
| void | applyRigidTransformation (const ccGLMatrix &trans) |
| Applies a rigid transformation (on the beam direction) More... | |
| uint8_t | returnIndex () const |
| Returns the return index. More... | |
| void | setReturnIndex (uint8_t index) |
| Sets the return index. More... | |
| bool | isSerializable () const override |
| Returns whether object is serializable of not. More... | |
| bool | toFile (QFile &out, short dataVersion) const override |
| Saves data to binary stream. More... | |
| short | minimumFileVersion () const override |
| Returns the minimum file version required to save this instance. More... | |
| bool | fromFile (QFile &in, short dataVersion, int flags, LoadedIDMap &oldToNewIDMap) override |
| Loads data from binary stream. More... | |
Public Member Functions inherited from ccSerializableObject | |
| virtual | ~ccSerializableObject ()=default |
| Destructor. More... | |
Static Public Member Functions | |
| static bool | ToASCII (const QString &filename, std::vector< double > &values, uint32_t samplingRate_ps) |
| Helper: exports a series of values as an ASCII file. More... | |
Static Public Member Functions inherited from ccSerializableObject | |
| static bool | WriteError () |
| Sends a custom error message (write error) and returns 'false'. More... | |
| static bool | ReadError () |
| Sends a custom error message (read error) and returns 'false'. More... | |
| static bool | MemoryError () |
| Sends a custom error message (not enough memory) and returns 'false'. More... | |
| static bool | CorruptError () |
| Sends a custom error message (corrupted file) and returns 'false'. More... | |
Protected Attributes | |
| uint32_t | m_byteCount |
| Waveform packet size in bytes. More... | |
| uint64_t | m_dataOffset |
| Byte offset to waveform data. More... | |
| CCVector3f | m_beamDir |
| Laser beam direction. More... | |
| float | m_echoTime_ps |
| Return Point location (in picoseconds) More... | |
| uint8_t | m_descriptorID |
| Wave Packet descriptor index. More... | |
| uint8_t | m_returnIndex |
| Return index. More... | |
Additional Inherited Members | |
Public Types inherited from ccSerializableObject | |
| enum | DeserializationFlags { DF_POINT_COORDS_64_BITS , DF_SCALAR_VAL_32_BITS = 2 } |
| Deserialization flags (bit-field) More... | |
| typedef QMultiMap< unsigned, unsigned > | LoadedIDMap |
| Map of loaded unique IDs (old ID --> new ID) More... | |
| ccWaveform::ccWaveform | ( | uint8_t | descriptorID = 0 | ) |
Default constructor.
|
overridedefault |
Destructor.
| void ccWaveform::applyRigidTransformation | ( | const ccGLMatrix & | trans | ) |
Applies a rigid transformation (on the beam direction)
Referenced by define_ccWaveform().
|
inline |
Returns the beam direction.
Definition at line 129 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LasWaveformSaver::handlePoint(), and LASFWFFilter::saveToFile().
|
inline |
Returns the number of allocated bytes.
Definition at line 112 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LasWaveformSaver::handlePoint(), and LASFWFFilter::saveToFile().
|
inline |
Gives access to the internal data.
Definition at line 121 of file ecvWaveform.h.
|
inline |
Returns the byte offset to waveform data.
Definition at line 115 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LasWaveformSaver::handlePoint(), and LASFWFFilter::saveToFile().
| bool ccWaveform::decodeSamples | ( | std::vector< double > & | values, |
| const WaveformDescriptor & | descriptor, | ||
| const uint8_t * | dataStorage | ||
| ) | const |
Decodes the samples and store them in a vector.
|
inline |
Returns the associated descriptor (ID)
Definition at line 67 of file ecvWaveform.h.
Referenced by define_ccWaveform(), and LasWaveformSaver::handlePoint().
|
inline |
Returns the echo time (in picoseconds)
Definition at line 135 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LasWaveformSaver::handlePoint(), and LASFWFFilter::saveToFile().
|
overridevirtual |
Loads data from binary stream.
| in | input file (already opened) |
| dataVersion | file version (for version-specific deserialization) |
| flags | deserialization flags (see ccSerializableObject::DeserializationFlags) |
| oldToNewIDMap | map to link old IDs with new IDs |
Note: When implementing, use dataVersion checks to handle differentversions:
Reimplemented from ccSerializableObject.
| double ccWaveform::getRange | ( | double & | minVal, |
| double & | maxVal, | ||
| const WaveformDescriptor & | descriptor, | ||
| const uint8_t * | dataStorage | ||
| ) | const |
Returns the range of (real) samples.
| uint32_t ccWaveform::getRawSample | ( | uint32_t | i, |
| const WaveformDescriptor & | descriptor, | ||
| const uint8_t * | dataStorage | ||
| ) | const |
Returns the (raw) value of a given sample.
Referenced by define_ccWaveform().
| double ccWaveform::getSample | ( | uint32_t | i, |
| const WaveformDescriptor & | descriptor, | ||
| const uint8_t * | dataStorage | ||
| ) | const |
Returns the (real) value of a given sample (in volts)
| CCVector3 ccWaveform::getSamplePos | ( | float | i, |
| const CCVector3 & | P0, | ||
| const WaveformDescriptor & | descriptor | ||
| ) | const |
Returns the sample position in 3D.
Referenced by define_ccWaveform().
|
inlineoverridevirtual |
Returns whether object is serializable of not.
Reimplemented from ccSerializableObject.
Definition at line 146 of file ecvWaveform.h.
|
overridevirtual |
Returns the minimum file version required to save this instance.
To be overridden by subclasses to indicate their minimum required version. This enables the system to determine:
Implements ccSerializableObject.
|
inline |
Returns the return index.
Definition at line 141 of file ecvWaveform.h.
Referenced by define_ccWaveform(), and LASFWFFilter::saveToFile().
|
inline |
Sets the beam direction.
Definition at line 126 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LASFWFFilter::loadFile(), and LasWaveformLoader::loadWaveform().
| void ccWaveform::setDataDescription | ( | uint64_t | dataOffset, |
| uint32_t | byteCount | ||
| ) |
Describes the waveform data.
Referenced by define_ccWaveform(), LASFWFFilter::loadFile(), and LasWaveformLoader::loadWaveform().
|
inline |
Sets the byte offset to waveform data.
Definition at line 118 of file ecvWaveform.h.
References offset.
Referenced by define_ccWaveform().
|
inline |
Sets the associated descriptor (ID)
Definition at line 70 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LASFWFFilter::loadFile(), and LasWaveformLoader::loadWaveform().
|
inline |
Set the echo time (in picoseconds)
Definition at line 132 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LASFWFFilter::loadFile(), and LasWaveformLoader::loadWaveform().
|
inline |
Sets the return index.
Definition at line 143 of file ecvWaveform.h.
Referenced by define_ccWaveform(), LASFWFFilter::loadFile(), and LasWaveformLoader::loadWaveform().
| bool ccWaveform::toASCII | ( | const QString & | filename, |
| const WaveformDescriptor & | descriptor, | ||
| const uint8_t * | dataStorage | ||
| ) | const |
Exports (real) samples to an ASCII file.
Referenced by define_ccWaveform().
|
static |
Helper: exports a series of values as an ASCII file.
Referenced by define_ccWaveform().
|
overridevirtual |
Saves data to binary stream.
| out | output file (already opened) |
| dataVersion | target file version (for forward/backward compatibility) |
Reimplemented from ccSerializableObject.
|
protected |
Laser beam direction.
Parametric line equation for extrapolating points along the associated waveform: X = X0 + X(t) Y = Y0 + Y(t) Z = Z0 + Z(t)
Definition at line 167 of file ecvWaveform.h.
|
protected |
Waveform packet size in bytes.
Definition at line 158 of file ecvWaveform.h.
|
protected |
Byte offset to waveform data.
Definition at line 161 of file ecvWaveform.h.
|
protected |
Wave Packet descriptor index.
Definition at line 180 of file ecvWaveform.h.
|
protected |
Return Point location (in picoseconds)
The offset in picoseconds from the first digitized value to the location within the waveform packet that the associated return pulse was detected.
Definition at line 174 of file ecvWaveform.h.
|
protected |
Return index.
Definition at line 183 of file ecvWaveform.h.