Labyrinth
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends
root.hpp
1 //////////////////////////////
2 //
3 // File: lxs/windowing/root.hpp
4 // Author: Maciej Kaminski
5 // E-mail: maciej.a.kaminski@gmail.com
6 // Website: maciejkaminski.pl
7 //
8 // File creation date: Feb 27 2013
9 // This file is part of Project Labyrinth
10 // This file is going to be released under terms of GNU GPL in near future
11 //
12 //////////////////////////////
13 
14 #ifndef __LXS_ROOT__
15 #define __LXS_ROOT__
16 #include "lxs/windowing/containerwindow.hpp"
17 namespace LxS
18 {
19  namespace CoreGraphics
20  {
21  class Renderable;
22  class Font;
23  }
24  namespace Audio
25  {
26  class Audio;
27  }
28  namespace Windowing
29  {
30  //! root window of an application
32  {
33  float framerate;
34  bool display_fps;
35  protected:
36  //! font for displaying i.e. framerate and other overlays
38 
39  //! audio-processing entity
41  public:
42  virtual void Animate(float dt);
43  //! is fps displayed by a window
44  bool GetDisplayFramerate() {return display_fps;}
45  //! display FPS (for performance diagnostics)
46  bool SetDisplayFramerate(bool disp_fps);
47  Root() {p_Audio=0;DefaultFont=0;}
48  void BackButtonPressed();
49  void ReplaceChild(Window * old_child, Window * new_child);
50  void JoystickAxes(int Axis, const float *direction);
51 
52  void ResizeHandler();
53  unsigned long GetTexelsCount();
54  unsigned long GetFacesCount();
55  virtual void Initialize();
56  virtual void UnloadResources();
57  //! get audio processing object
59  ~Root();
60  };
61  }
62 }
63 
64 #endif