ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
RgbDialog.h
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 
8 #pragma once
9 
10 // ##########################################################################
11 // # #
12 // # CLOUDVIEWER PLUGIN: ColorimetricSegmenter #
13 // # #
14 // # This program is free software; you can redistribute it and/or modify #
15 // # it under the terms of the GNU General Public License as published by #
16 // # the Free Software Foundation; version 2 of the License. #
17 // # #
18 // # This program is distributed in the hope that it will be useful, #
19 // # but WITHOUT ANY WARRANTY; without even the implied warranty of #
20 // # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
21 // # GNU General Public License for more details. #
22 // # #
23 // # COPYRIGHT: Tri-Thien TRUONG, Ronan COLLIER, Mathieu LETRONE #
24 // # #
25 // ##########################################################################
26 
27 #include <ecvPickingListener.h>
28 #include <ui_RgbDialog.h>
29 
30 // Qt
31 #include <QDialog>
32 
33 class ccPickingHub;
34 /*
35  Get the values of the RGB interface, and interactions
36 */
37 class RgbDialog : public QDialog,
38  public ccPickingListener,
39  public Ui::RgbDialog {
40  Q_OBJECT
41 public:
42  explicit RgbDialog(ccPickingHub* pickingHub, QWidget* parent = nullptr);
43 
45  virtual void onItemPicked(const PickedItem& pi);
46 
47 public slots:
48  void pickPoint_first(bool);
49  void pickPoint_second(bool);
50 
51 protected: // members
53  QWidget* m_pickingWin;
54 
57 };
RgbDialog.h
ccObject::isKindOf
bool isKindOf(CV_CLASS_ENUM type) const
Definition: ecvObject.h:128
rgb
normal_z rgb
Definition: my_point_types.h:168
RgbDialog::RgbDialog
RgbDialog(ccPickingHub *pickingHub, QWidget *parent=nullptr)
Definition: RgbDialog.cpp:20
RgbDialog::m_pickingWin
QWidget * m_pickingWin
Picking window (if any)
Definition: RgbDialog.h:53
RgbDialog
Definition: RgbDialog.h:37
ccPickingHub::addListener
bool addListener(ccPickingListener *listener, bool exclusive=false, bool autoStartPicking=true, ecvDisplayTools::PICKING_MODE mode=ecvDisplayTools::POINT_OR_TRIANGLE_PICKING)
Adds a listener.
Definition: ecvPickingHub.cpp:104
CVLog::Print
static bool Print(const char *format,...)
Prints out a formatted message in console.
Definition: CVLog.cpp:113
CV_TYPES::POINT_CLOUD
@ POINT_CLOUD
Definition: CVTypes.h:104
ccPickingListener
Point/triangle picking listener interface.
Definition: ecvPickingListener.h:21
RgbDialog::pickPoint_second
void pickPoint_second(bool)
Definition: RgbDialog.cpp:70
CVLog::Error
static bool Error(const char *format,...)
Display an error dialog with formatted message.
Definition: CVLog.cpp:143
RgbDialog::pickPoint_first
void pickPoint_first(bool)
Definition: RgbDialog.cpp:48
slots
#define slots
Definition: PythonPlugin.cpp:25
ccPickingListener::PickedItem::entity
ccHObject * entity
Definition: ecvPickingListener.h:30
RgbDialog::onItemPicked
virtual void onItemPicked(const PickedItem &pi)
Inherited from ccPickingListener.
Definition: RgbDialog.cpp:92
ccGenericPointCloud
A 3D cloud interface with associated features (color, normals, octree, etc.)
Definition: ecvGenericPointCloud.h:45
ecvGenericPointCloud.h
Ui
Definition: sfEditDlg.h:16
ccGenericPointCloud::getPointColor
virtual const ecvColor::Rgb & getPointColor(unsigned pointIndex) const =0
Returns color corresponding to a given point.
ecvPickingHub.h
ecvPickingListener.h
ccPickingListener::PickedItem::itemIndex
unsigned itemIndex
Definition: ecvPickingListener.h:31
ecvColor::RgbTpl
RGB color structure.
Definition: ecvColorTypes.h:49
ccPickingHub
Point/triangle picking hub.
Definition: ecvPickingHub.h:29
ccDrawableObject::hasColors
virtual bool hasColors() const
Returns whether colors are enabled or not.
Definition: ecvDrawableObject.h:80
ccPickingListener::PickedItem
Picked item.
Definition: ecvPickingListener.h:26
ccPickingHub::activeWindow
QWidget * activeWindow() const
Returns the currently active window.
Definition: ecvPickingHub.h:74
ccPickingHub::removeListener
void removeListener(ccPickingListener *listener, bool autoStopPickingIfLast=true)
Removes a listener.
Definition: ecvPickingHub.cpp:165
RgbDialog::m_pickingHub
ccPickingHub * m_pickingHub
Picking hub.
Definition: RgbDialog.h:56