qCC version 2.13.alpha (Qt) - 31 May 2022
Main CloudCompare application (GUI & command line)
Classes | Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
ccVolumeCalcTool Class Reference

Volume calculation tool (dialog) More...

#include <ccVolumeCalcTool.h>

Inheritance diagram for ccVolumeCalcTool:
Inheritance graph
[legend]
Collaboration diagram for ccVolumeCalcTool:
Collaboration graph
[legend]

Classes

struct  ReportInfo
 Report info. More...
 

Public Member Functions

 ccVolumeCalcTool (ccGenericPointCloud *cloud1, ccGenericPointCloud *cloud2, QWidget *parent=nullptr)
 Default constructor.
 
 ~ccVolumeCalcTool ()
 Destructor.
 
virtual double getGridStep () const override
 Returns projection grid step. More...
 
virtual unsigned char getProjectionDimension () const override
 Returns projection dimension. More...
 
virtual ccRasterGrid::ProjectionType getTypeOfProjection () const override
 Returns type of projection. More...
 
- Public Member Functions inherited from cc2Point5DimEditor
 cc2Point5DimEditor ()
 Default constructor.
 
virtual ~cc2Point5DimEditor ()
 Destructor.
 

Static Public Member Functions

static bool ComputeVolume (ccRasterGrid &grid, ccGenericPointCloud *ground, ccGenericPointCloud *ceil, const ccBBox &gridBox, unsigned char vertDim, double gridStep, unsigned gridWidth, unsigned gridHeight, ccRasterGrid::ProjectionType projectionType, ccRasterGrid::EmptyCellFillOption groundEmptyCellFillStrategy, double groundMaxEdgeLength, ccRasterGrid::EmptyCellFillOption ceilEmptyCellFillStrategy, double ceilMaxEdgeLength, ccVolumeCalcTool::ReportInfo &reportInfo, double groundHeight, double ceilHeight, QWidget *parentWidget=nullptr)
 Static accessor.
 
static ccPointCloud * ConvertGridToCloud (ccRasterGrid &grid, const ccBBox &gridBox, unsigned char vertDim, bool exportToOriginalCS)
 Converts a (volume) grid to a point cloud.
 

Protected Member Functions

void saveSettingsAndAccept ()
 Accepts the dialog and save settings.
 
void saveSettings ()
 Save persistent settings and 'accept' dialog.
 
void projectionDirChanged (int)
 Called when the projection direction changes.
 
void sfProjectionTypeChanged (int)
 Called when the SF projection type changes.
 
virtual bool showGridBoxEditor () override
 Show grid box editor and update. More...
 
void groundFillEmptyCellStrategyChanged (int)
 Called when the (ground) empty cell filling strategy changes.
 
void ceilFillEmptyCellStrategyChanged (int)
 Called when the (ceil) empty cell filling strategy changes.
 
void gridOptionChanged ()
 Called when the an option of the grid generation has changed.
 
void updateGridInfo ()
 Updates the gid info.
 
void updateGridAndDisplay ()
 Update the grid and the 2D display.
 
void swapRoles ()
 Swap roles.
 
void groundSourceChanged (int)
 Ground source changed.
 
void ceilSourceChanged (int)
 Ceil source changed.
 
void exportToClipboard () const
 Exports info to clipboard.
 
void exportGridAsCloud () const
 Exports the grid as a point cloud.
 
void setDisplayedNumberPrecision (int)
 Sets the displayed number precision.
 
std::pair< ccGenericPointCloud *, double > getGroundCloud () const
 Returns the ground cloud (or constant height)
 
std::pair< ccGenericPointCloud *, double > getCeilCloud () const
 Returns the ceil cloud (or constant height)
 
virtual void gridIsUpToDate (bool state) override
 Declares whether the grid is up-to-date or not. More...
 
void loadSettings ()
 Load persistent settings.
 
bool updateGrid ()
 Updates the grid.
 
ccPointCloud * convertGridToCloud (bool exportToOriginalCS) const
 Converts the grid to a point cloud.
 
void outputReport (const ReportInfo &info)
 Outputs the report.
 
- Protected Member Functions inherited from cc2Point5DimEditor
virtual double getGridStep () const =0
 Returns projection grid step. More...
 
virtual unsigned char getProjectionDimension () const =0
 Returns projection dimension. More...
 
virtual ccRasterGrid::ProjectionType getTypeOfProjection () const =0
 Returns type of projection. More...
 
virtual ccBBox getCustomBBox () const
 Returns custom bbox.
 
virtual void gridIsUpToDate (bool state)=0
 Declares whether the grid is up-to-date or not. More...
 
virtual void update2DDisplayZoom (ccBBox &box)
 Updates the 2D display zoom.
 
virtual bool showGridBoxEditor ()
 Show grid box editor and update. More...
 
virtual QString getGridSizeAsString () const
 Returns the grid size as a string.
 
virtual bool getGridSize (unsigned &width, unsigned &height) const
 Returns the grid size.
 
void createBoundingBoxEditor (const ccBBox &gridBBox, QWidget *parent)
 Creates the bounding-box editor.
 
void create2DView (QFrame *parentFrame)
 Creates the 2D view.
 
ccRasterGrid::EmptyCellFillOption getFillEmptyCellsStrategy (QComboBox *comboBox) const
 Returns the empty cell strategy (for a given combo-box)
 
ccPointCloud * convertGridToCloud (const std::vector< ccRasterGrid::ExportableFields > &exportedFields, bool interpolateSF, bool interpolateColors, bool resampleInputCloudXY, bool resampleInputCloudZ, ccGenericPointCloud *inputCloud, bool fillEmptyCells, double emptyCellsHeight, bool exportToOriginalCS) const
 Shortcut to ccRasterGrid::convertToCloud.
 

Protected Attributes

ccGenericPointCloud * m_cloud1
 First associated cloud.
 
ccGenericPointCloud * m_cloud2
 Second associated cloud.
 
ReportInfo m_lastReport
 Last report. More...
 
Ui::VolumeCalcDialog * m_ui
 
- Protected Attributes inherited from cc2Point5DimEditor
ccRasterGrid m_grid
 Raster grid.
 
ccBoundingBoxEditorDlgm_bbEditorDlg
 Associated dialog.
 
ccGLWindow * m_glWindow
 2D display
 
ccPointCloud * m_rasterCloud
 'Raster' cloud
 

Detailed Description

Volume calculation tool (dialog)

Member Function Documentation

◆ getGridStep()

double ccVolumeCalcTool::getGridStep ( ) const
overridevirtual

Returns projection grid step.

Implements cc2Point5DimEditor.

◆ getProjectionDimension()

unsigned char ccVolumeCalcTool::getProjectionDimension ( ) const
overridevirtual

Returns projection dimension.

Returns
dimension as int (0: X, 1: Y, 2:Z)

Implements cc2Point5DimEditor.

◆ getTypeOfProjection()

ccRasterGrid::ProjectionType ccVolumeCalcTool::getTypeOfProjection ( ) const
overridevirtual

Returns type of projection.

Implements cc2Point5DimEditor.

◆ gridIsUpToDate()

void ccVolumeCalcTool::gridIsUpToDate ( bool  state)
overrideprotectedvirtual

Declares whether the grid is up-to-date or not.

Implements cc2Point5DimEditor.

◆ showGridBoxEditor()

bool ccVolumeCalcTool::showGridBoxEditor ( )
overrideprotectedvirtual

Show grid box editor and update.

Returns
whether the box was modified or not

Reimplemented from cc2Point5DimEditor.

Member Data Documentation

◆ m_lastReport

ReportInfo ccVolumeCalcTool::m_lastReport
protected

Last report.

Only valid if clipboardPushButton is enabled


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