PdfPlot.h
Go to the documentation of this file.
1 /*
2 Copyright (c) 2010-2016, Mathieu Labbe - IntRoLab - Universite de Sherbrooke
3 All rights reserved.
4 
5 Redistribution and use in source and binary forms, with or without
6 modification, are permitted provided that the following conditions are met:
7  * Redistributions of source code must retain the above copyright
8  notice, this list of conditions and the following disclaimer.
9  * Redistributions in binary form must reproduce the above copyright
10  notice, this list of conditions and the following disclaimer in the
11  documentation and/or other materials provided with the distribution.
12  * Neither the name of the Universite de Sherbrooke nor the
13  names of its contributors may be used to endorse or promote products
14  derived from this software without specific prior written permission.
15 
16 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
17 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
18 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
19 DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY
20 DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
21 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
22 LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
23 ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
25 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 */
27 
28 #ifndef RTABMAP_PDFPLOT_H_
29 #define RTABMAP_PDFPLOT_H_
30 
31 #include "rtabmap/gui/RtabmapGuiExp.h" // DLL export/import defines
32 
33 #include <rtabmap/utilite/UPlot.h>
34 #include "opencv2/opencv.hpp"
35 #include "rtabmap/core/Signature.h"
36 
37 namespace rtabmap {
38 
40 {
41 public:
42  PdfPlotItem(float dataX, float dataY, float width, int childCount = -1);
43  virtual ~PdfPlotItem();
44 
45  void setLikelihood(int id, float value, int childCount);
46  void setSignaturesRef(const QMap<int, Signature> * signaturesRef) {_signaturesRef = signaturesRef;}
47 
48  float value() const {return this->data().y();}
49  int id() const {return this->data().x();}
50 
51 protected:
52  virtual void showDescription(bool shown);
53 
54 private:
55  QGraphicsPixmapItem * _img;
57  const QMap<int, Signature> * _signaturesRef;
58  QGraphicsTextItem * _text;
59 
60 };
61 
63 {
64  Q_OBJECT
65 
66 public:
67  PdfPlotCurve(const QString & name, const QMap<int, Signature> * signaturesMapRef, QObject * parent = 0);
68  virtual ~PdfPlotCurve();
69 
70  virtual void clear();
71  void setData(const QMap<int, float> & dataMap, const QMap<int, int> & weightsMap);
72 
73 private:
74  const QMap<int, Signature> * _signaturesMapRef;
75 };
76 
77 }
78 
79 #endif /* PDFPLOT_H_ */
#define RTABMAPGUI_EXP
Definition: RtabmapGuiExp.h:38
QGraphicsPixmapItem * _img
Definition: PdfPlot.h:55
float value() const
Definition: PdfPlot.h:48
const QMap< int, Signature > * _signaturesRef
Definition: PdfPlot.h:57
void setSignaturesRef(const QMap< int, Signature > *signaturesRef)
Definition: PdfPlot.h:46
int id() const
Definition: PdfPlot.h:49
const QMap< int, Signature > * _signaturesMapRef
Definition: PdfPlot.h:74
QGraphicsTextItem * _text
Definition: PdfPlot.h:58


rtabmap
Author(s): Mathieu Labbe
autogenerated on Mon Dec 14 2020 03:34:59