ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
ecvPrimitiveDistanceDlg.cpp
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - CloudViewer: www.cloudViewer.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2024 www.cloudViewer.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
9 
10 // Qt
11 #include <QHeaderView>
12 #include <QMessageBox>
13 
14 // System
15 #include <assert.h>
16 
17 static bool s_signedDist = true;
18 static bool s_flipNormals = false;
19 static bool s_treatAsBounded = false;
21  : QDialog(parent, Qt::Tool), Ui::primitiveDistanceDlg() {
22  setupUi(this);
23 
24  signedDistCheckBox->setChecked(s_signedDist);
25  flipNormalsCheckBox->setEnabled(s_signedDist);
26  flipNormalsCheckBox->setChecked(s_flipNormals);
27  treatPlanesAsBoundedCheckBox->setUpdatesEnabled(false);
28  treatPlanesAsBoundedCheckBox->setChecked(s_treatAsBounded);
29  connect(cancelButton, &QPushButton::clicked, this,
31  connect(okButton, &QPushButton::clicked, this,
33  connect(signedDistCheckBox, &QCheckBox::toggled, this,
35 }
36 
41  accept();
42 }
43 
45 
47  flipNormalsCheckBox->setEnabled(state);
48 }
ecvPrimitiveDistanceDlg(QWidget *parent=nullptr)
Default constructor.
static bool s_treatAsBounded
static bool s_signedDist
static bool s_flipNormals