VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DtDiGuyScenario.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 2013 MAK Technologies, Inc.
3 ** All rights reserved.
4 ******************************************************************************/
5 
8 
9 #pragma once
10 #include <vrvDiGuy/vrvDiGuy.h>
12 #include <vrvCore/DtUniqueID.h>
13 
14 #include <osg/Group>
15 
16 class diguyScenario;
17 
18 namespace makVrv
19 {
20  class DtDe;
21  class DtWindow;
22 
26  {
27  public:
28 
30  static DtDiGuyScenario& instance(DtDe& de);
31 
33  virtual ~DtDiGuyScenario();
34 
36  diguyScenario& scenario();
37 
38  void clearScene();
39 
41  virtual osg::Node* characterRoot();
42 
43  int get_use_guides(){return m_use_guides;}
44  float get_guide_sync_gain(){return m_guide_sync_gain;}
45  int get_use_instancing(){return m_use_instancing;}
46 
47  const char * mapEffect(const char * diguy_effect_name);
48 
49  float getCharacterDrawDistance(){return myCharacterDrawDistance;}
50 
51  // Finds the character name, given the parent scene object ID
52  std::string findCharacterName(DtElementID parentSceneObjectID);
53 
54  // Evaluates a script using the diguyScenario's interpreter.
55  bool evalScript(const std::string & script);
56 
57  protected:
59  virtual void slot_windowDestroyed(DtWindow* window);
60 
62  virtual void slot_windowCreated(DtWindow* window);
63 
65  virtual void slot_reloadShader();
66 
68  virtual void slot_preDraw();
69 
71  virtual void slot_postDraw();
72 
73  protected:
74 
75  void updateScenario(double simTime);
76  void setComponentVisualizationMode(int mode);
77 
78  DtDiGuyScenario(DtDe& de);
79 
80  void create_diguy_scenario();
81 
82  void reload_config_info();
83 
85  diguyScenario* myScenario;
86 
87  osg::ref_ptr<osg::Group> myCharacterRoot;
92 
94 
96 
97  };
98 }

Document ID: Generated on Tue Mar 8 22:13:38 EST 2016 from SVN revision 162938
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)