VisualObject.h
Go to the documentation of this file.
1 /*+-------------------------------------------------------------------------+
2  | MultiVehicle simulator (libmvsim) |
3  | |
4  | Copyright (C) 2014 Jose Luis Blanco Claraco (University of Almeria) |
5  | Copyright (C) 2017 Borys Tymchenko (Odessa Polytechnic University) |
6  | Distributed under GNU General Public License version 3 |
7  | See <http://www.gnu.org/licenses/> |
8  +-------------------------------------------------------------------------+ */
9 
10 #pragma once
11 
12 #include <mvsim/basic_types.h>
13 
14 namespace mvsim
15 {
16 class World;
17 
21 {
22  public:
23  VisualObject(World* parent) : m_world(parent) {}
24  virtual ~VisualObject() {}
27  virtual void gui_update(mrpt::opengl::COpenGLScene& scene) = 0;
28 
29  World* getWorldObject() { return m_world; }
30  const World* getWorldObject() const { return m_world; }
31  protected:
33 };
34 }
35 
37 #define SCENE_INSERT_Z_ORDER(_SCENE, _ZORDER_INDEX, _OBJ_TO_INSERT) \
38  mrpt::ptr_cast<mrpt::opengl::CSetOfObjects>::from( \
39  _SCENE.getByName("level_" #_ZORDER_INDEX)) \
40  ->insert(_OBJ_TO_INSERT)
World * getWorldObject()
Definition: VisualObject.h:29
VisualObject(World *parent)
Definition: VisualObject.h:23
virtual void gui_update(mrpt::opengl::COpenGLScene &scene)=0
const World * getWorldObject() const
Definition: VisualObject.h:30
virtual ~VisualObject()
Definition: VisualObject.h:24


mvsim
Author(s):
autogenerated on Thu Jun 6 2019 19:36:40