LVRFilteringRemoveOutliersDialog.cpp
Go to the documentation of this file.
1 
28 #include <QFileDialog>
30 
31 namespace lvr2
32 {
33 
34 LVRRemoveOutliersDialog::LVRRemoveOutliersDialog(LVRPointCloudItem* pc, LVRModelItem* parent, QTreeWidget* treeWidget, vtkRenderWindow* window) :
35  m_pc(pc), m_parent(parent), m_treeWidget(treeWidget), m_renderWindow(window)
36 {
37  // Setup DialogUI and events
38  QDialog* dialog = new QDialog(m_treeWidget);
39  m_dialog = new RemoveOutliersDialog;
40  m_dialog->setupUi(dialog);
41 
43 
44  dialog->show();
45  dialog->raise();
46  dialog->activateWindow();
47 }
48 
50 {
51  // TODO Auto-generated destructor stub
52 }
53 
55 {
56  QObject::connect(m_dialog->buttonBox, SIGNAL(accepted()), this, SLOT(removeOutliers()));
57 }
58 
60 {
61  QDoubleSpinBox* standardDeviation_box = m_dialog->doubleSpinBox_st;
62  float standardDeviation = (float)standardDeviation_box->value();
63  QDoubleSpinBox* meanK_box = m_dialog->doubleSpinBox_st;
64  float meanK = (float)meanK_box->value();
65  /*
66  PCLFiltering filter(m_pc->getPointBuffer());
67  filter.applyOutlierRemoval(meanK, standardDeviation);
68 
69  PointBufferPtr pb( filter.getPointBuffer() );
70  ModelPtr model( new Model( pb ) );
71 
72  ModelBridgePtr bridge(new LVRModelBridge(model));
73  vtkSmartPointer<vtkRenderer> renderer = m_renderWindow->GetRenderers()->GetFirstRenderer();
74  bridge->addActors(renderer);
75 
76  QString base = m_parent->getName() + " (rem. outliers)";
77  m_optimizedPointCloud = new LVRModelItem(bridge, base);
78 
79  m_treeWidget->addTopLevelItem(m_optimizedPointCloud);
80  m_optimizedPointCloud->setExpanded(true); */
81 }
82 
83 } // namespace lvr2
lvr2::LVRPointCloudItem
Definition: LVRPointCloudItem.hpp:45
lvr2::LVRRemoveOutliersDialog::m_treeWidget
QTreeWidget * m_treeWidget
Definition: LVRFilteringRemoveOutliersDialog.hpp:68
lvr2::LVRRemoveOutliersDialog::connectSignalsAndSlots
void connectSignalsAndSlots()
Definition: LVRFilteringRemoveOutliersDialog.cpp:54
lvr2::LVRRemoveOutliersDialog::m_dialog
RemoveOutliersDialog * m_dialog
Definition: LVRFilteringRemoveOutliersDialog.hpp:64
lvr2::LVRRemoveOutliersDialog::LVRRemoveOutliersDialog
LVRRemoveOutliersDialog(LVRPointCloudItem *pc_item, LVRModelItem *parent, QTreeWidget *treeWidget, vtkRenderWindow *renderer)
Definition: LVRFilteringRemoveOutliersDialog.cpp:34
lvr2::LVRModelItem
Definition: LVRModelItem.hpp:47
lvr2
Definition: BaseBufferManipulators.hpp:39
lvr2::LVRRemoveOutliersDialog::removeOutliers
void removeOutliers()
Definition: LVRFilteringRemoveOutliersDialog.cpp:59
LVRFilteringRemoveOutliersDialog.hpp
lvr2::LVRRemoveOutliersDialog::~LVRRemoveOutliersDialog
virtual ~LVRRemoveOutliersDialog()
Definition: LVRFilteringRemoveOutliersDialog.cpp:49


lvr2
Author(s): Thomas Wiemann , Sebastian Pütz , Alexander Mock , Lars Kiesow , Lukas Kalbertodt , Tristan Igelbrink , Johan M. von Behren , Dominik Feldschnieders , Alexander Löhr
autogenerated on Wed Mar 2 2022 00:37:24