ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
LasSaveDialog Class Reference

#include <LasSaveDialog.h>

Inheritance diagram for LasSaveDialog:
Collaboration diagram for LasSaveDialog:

Public Slots

void handleSelectedVersionChange (const QString &)
 
void handleSelectedPointFormatChange (int index)
 When the user changes the point format, we need to update the scalar field form. More...
 
void handleComboBoxChange (int index)
 
void addExtraScalarFieldCard ()
 

Public Member Functions

 LasSaveDialog (ccPointCloud *cloud, QWidget *parent=nullptr)
 
void setVersionAndPointFormat (const LasDetails::LasVersion versionAndFmt)
 
void setOptimalScale (const CCVector3d &scale, bool autoCheck=false)
 Set scale that would offer the user the best precision. More...
 
void setOriginalScale (const CCVector3d &scale, bool canUseScale, bool autoCheck=true)
 
void setExtraScalarFields (const std::vector< LasExtraScalarField > &extraScalarFields)
 Set the extra LAS scalar fields saved from the original file. More...
 
uint8_t selectedPointFormat () const
 Returns the point format currently selected. More...
 
void selectedVersion (uint8_t &versionMajor, uint8_t &versionMinor) const
 Returns the version currently selected. More...
 
CCVector3d chosenScale () const
 Returns the currently selected scale. More...
 
bool shouldSaveRGB () const
 Returns whether the user wants to save RGB. More...
 
bool shouldSaveWaveform () const
 Returns whether the user wants to save the Waveforms. More...
 
std::vector< LasScalarFieldfieldsToSave () const
 
std::vector< LasExtraScalarFieldextraFieldsToSave () const
 

Detailed Description

This dialog is responsible for presenting to the user the different options when saving a point cloud to a LAS/LAZ file.

Definition at line 47 of file LasSaveDialog.h.

Constructor & Destructor Documentation

◆ LasSaveDialog()

Member Function Documentation

◆ addExtraScalarFieldCard

void LasSaveDialog::addExtraScalarFieldCard ( )
slot

Definition at line 362 of file LasSaveDialog.cpp.

References max().

Referenced by LasSaveDialog().

◆ chosenScale()

CCVector3d LasSaveDialog::chosenScale ( ) const

Returns the currently selected scale.

Definition at line 499 of file LasSaveDialog.cpp.

References Tuple3Tpl< Type >::x, Tuple3Tpl< Type >::y, and Tuple3Tpl< Type >::z.

Referenced by LasIOFilter::saveToFile().

◆ extraFieldsToSave()

std::vector< LasExtraScalarField > LasSaveDialog::extraFieldsToSave ( ) const

Definition at line 557 of file LasSaveDialog.cpp.

References CVLog::Error().

Referenced by LasIOFilter::saveToFile().

◆ fieldsToSave()

std::vector< LasScalarField > LasSaveDialog::fieldsToSave ( ) const

Returns the vector of LAS scalar fields the user wants to save.

Each LAS scalar fields is mapped to an existing point cloud's ccScalarField. The mapping is done by us and the user.

Definition at line 521 of file LasSaveDialog.cpp.

References fields, cloudViewer::PointCloudTpl< T >::getScalarField(), cloudViewer::PointCloudTpl< T >::getScalarFieldIndexByName(), LasScalarField::IdFromName(), name, and selectedPointFormat().

Referenced by LasIOFilter::saveToFile().

◆ handleComboBoxChange

void LasSaveDialog::handleComboBoxChange ( int  index)
slot

◆ handleSelectedPointFormatChange

void LasSaveDialog::handleSelectedPointFormatChange ( int  index)
slot

◆ handleSelectedVersionChange

void LasSaveDialog::handleSelectedVersionChange ( const QString &  version)
slot

When the selected version changes, we need to update the combo box of point format to match the ones supported by the version

Definition at line 147 of file LasSaveDialog.cpp.

References handleSelectedPointFormatChange(), LasDetails::PointFormatsAvailableForVersion(), and version.

Referenced by LasSaveDialog().

◆ selectedPointFormat()

uint8_t LasSaveDialog::selectedPointFormat ( ) const

Returns the point format currently selected.

Definition at line 466 of file LasSaveDialog.cpp.

References min().

Referenced by fieldsToSave(), handleComboBoxChange(), handleSelectedPointFormatChange(), and LasIOFilter::saveToFile().

◆ selectedVersion()

void LasSaveDialog::selectedVersion ( uint8_t &  versionMajor,
uint8_t &  versionMinor 
) const

Returns the version currently selected.

Definition at line 471 of file LasSaveDialog.cpp.

References min(), and qtCompatSplitRefChar().

Referenced by LasIOFilter::saveToFile().

◆ setExtraScalarFields()

void LasSaveDialog::setExtraScalarFields ( const std::vector< LasExtraScalarField > &  extraScalarFields)

Set the extra LAS scalar fields saved from the original file.

Definition at line 451 of file LasSaveDialog.cpp.

Referenced by LasIOFilter::saveToFile().

◆ setOptimalScale()

void LasSaveDialog::setOptimalScale ( const CCVector3d scale,
bool  autoCheck = false 
)

Set scale that would offer the user the best precision.

Definition at line 419 of file LasSaveDialog.cpp.

References Tuple3Tpl< Type >::x, Tuple3Tpl< Type >::y, and Tuple3Tpl< Type >::z.

Referenced by LasIOFilter::saveToFile().

◆ setOriginalScale()

void LasSaveDialog::setOriginalScale ( const CCVector3d scale,
bool  canUseScale,
bool  autoCheck = true 
)

Set the scale that was used in the original file to save comes from.

Definition at line 432 of file LasSaveDialog.cpp.

References Tuple3Tpl< Type >::x, Tuple3Tpl< Type >::y, and Tuple3Tpl< Type >::z.

Referenced by LasIOFilter::saveToFile().

◆ setVersionAndPointFormat()

void LasSaveDialog::setVersionAndPointFormat ( const LasDetails::LasVersion  versionAndFmt)

◆ shouldSaveRGB()

bool LasSaveDialog::shouldSaveRGB ( ) const

Returns whether the user wants to save RGB.

Definition at line 489 of file LasSaveDialog.cpp.

Referenced by LasIOFilter::saveToFile().

◆ shouldSaveWaveform()

bool LasSaveDialog::shouldSaveWaveform ( ) const

Returns whether the user wants to save the Waveforms.

Definition at line 494 of file LasSaveDialog.cpp.

Referenced by LasIOFilter::saveToFile().


The documentation for this class was generated from the following files: