graphicalmarkers.h
Go to the documentation of this file.
1 /********************************************************************************
2  * FARSA Experiments Library *
3  * Copyright (C) 2007-2012 *
4  * Stefano Nolfi <stefano.nolfi@istc.cnr.it> *
5  * Onofrio Gigliotta <onofrio.gigliotta@istc.cnr.it> *
6  * Gianluca Massera <emmegian@yahoo.it> *
7  * Tomassino Ferrauto <tomassino.ferrauto@istc.cnr.it> *
8  * *
9  * This program is free software; you can redistribute it and/or modify *
10  * it under the terms of the GNU General Public License as published by *
11  * the Free Software Foundation; either version 2 of the License, or *
12  * (at your option) any later version. *
13  * *
14  * This program is distributed in the hope that it will be useful, *
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
17  * GNU General Public License for more details. *
18  * *
19  * You should have received a copy of the GNU General Public License *
20  * along with this program; if not, write to the Free Software *
21  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA *
22  ********************************************************************************/
23 
24 #ifndef GRAPHICALMARKERS_H
25 #define GRAPHICALMARKERS_H
26 
27 #include "worldsimconfig.h"
28 #include "world.h"
29 #include "renderworld.h"
30 #include "graphicalwobject.h"
31 
39 namespace farsa {
40 
47 class FARSA_WSIM_API CircularGraphicalMarker : public GraphicalWObject
48 {
49  Q_OBJECT
50 
51 public:
60  CircularGraphicalMarker(real radius, World* world, QString name = "unamed", const wMatrix& tm = wMatrix::identity());
61 
65  virtual ~CircularGraphicalMarker();
66 
67 protected:
76  virtual void render(RenderWObject* renderer, QGLContext* gw);
77 
78 private:
82  const real m_radius;
83 };
84 
92 class FARSA_WSIM_API PlanarArrowGraphicalMarker : public GraphicalWObject
93 {
94  Q_OBJECT
95 
96 public:
109  PlanarArrowGraphicalMarker(real arrowLength, real arrowTailWidth, real arrowHeadWidth, real arrowTailPortion, World* world, QString name = "unamed", const wMatrix& tm = wMatrix::identity());
110 
114  virtual ~PlanarArrowGraphicalMarker();
115 
116 protected:
125  virtual void render(RenderWObject* renderer, QGLContext* gw);
126 
127 private:
131  const real m_arrowLength;
132 
136  const real m_arrowTailWidth;
137 
141  const real m_arrowHeadWidth;
142 
148  const real m_arrowTailPortion;
149 };
150 
151 }
152 
153 #endif