| 1 |
//########################################################################## |
| 2 |
//# # |
| 3 |
//# CLOUDCOMPARE PLUGIN: qCANUPO # |
| 4 |
//# # |
| 5 |
//# This program is free software; you can redistribute it and/or modify # |
| 6 |
//# it under the terms of the GNU General Public License as published by # |
| 7 |
//# the Free Software Foundation; version 2 or later of the License. # |
| 8 |
//# # |
| 9 |
//# This program is distributed in the hope that it will be useful, # |
| 10 |
//# but WITHOUT ANY WARRANTY; without even the implied warranty of # |
| 11 |
//# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # |
| 12 |
//# GNU General Public License for more details. # |
| 13 |
//# # |
| 14 |
//# COPYRIGHT: UEB (UNIVERSITE EUROPEENNE DE BRETAGNE) / CNRS # |
| 15 |
//# # |
| 16 |
//########################################################################## |
| 17 |
|
| 18 |
#ifndef Q_CANUPO_TRAINING_DIALOG_HEADER |
| 19 |
#define Q_CANUPO_TRAINING_DIALOG_HEADER |
| 20 |
|
| 21 |
#include <ui_qCanupoTrainingDialog.h> |
| 22 |
|
| 23 |
class ccMainAppInterface; |
| 24 |
class ccPointCloud; |
| 25 |
|
| 26 |
//! CANUPO plugin's training dialog |
| 27 |
class qCanupoTrainingDialog : public QDialog, public Ui::CanupoTrainingDialog |
| 28 |
{ |
| 29 |
Q_OBJECT |
| 30 |
|
| 31 |
public: |
| 32 |
|
| 33 |
//! Default constructor |
| 34 |
qCanupoTrainingDialog(ccMainAppInterface* app); |
| 35 |
|
| 36 |
//! Get origin point cloud |
| 37 |
ccPointCloud* getOriginPointCloud(); |
| 38 |
//! Get class #1 point cloud |
| 39 |
ccPointCloud* getClass1Cloud(); |
| 40 |
//! Get class #2 point cloud |
| 41 |
ccPointCloud* getClass2Cloud(); |
| 42 |
//! Get evaluation point cloud |
| 43 |
ccPointCloud* getEvaluationCloud(); |
| 44 |
|
| 45 |
//! Loads parameters from persistent settings |
| 46 |
void loadParamsFromPersistentSettings(); |
| 47 |
//! Saves parameters to persistent settings |
| 48 |
void saveParamsToPersistentSettings(); |
| 49 |
|
| 50 |
//! Returns input scales |
| 51 |
bool getScales(std::vector<float>& scales) const; |
| 52 |
//! Returns the max number of threads to use |
| 53 |
int getMaxThreadCount() const; |
| 54 |
|
| 55 |
//! Returns the selected descriptor ID |
| 56 |
unsigned getDescriptorID() const; |
| 57 |
|
| 58 |
protected: |
| 59 |
|
| 60 |
void onClassChanged(int); |
| 61 |
void onCloudChanged(int); |
| 62 |
|
| 63 |
protected: |
| 64 |
|
| 65 |
//! Gives access to the application (data-base, UI, etc.) |
| 66 |
ccMainAppInterface* m_app; |
| 67 |
|
| 68 |
//Returns whether the current parameters are valid or not |
| 69 |
bool validParameters() const; |
| 70 |
|
| 71 |
}; |
| 72 |
|
| 73 |
#endif //Q_CANUPO_TRAINING_DIALOG_HEADER |