Blowbox 2017
A 3D Game Engine by Riko Ophorst using DirectX 12
glfw_manager.h
1 #pragma once
2 
3 #include "util/map.h"
4 
5 struct GLFWwindow;
6 
7 namespace blowbox
8 {
9  class Window;
10 
17  {
18  friend class BlowboxCore;
19  friend class Window;
20  public:
25  GLFWManager();
26 
31  ~GLFWManager();
32 
33  protected:
38  void Init();
39 
44  void Update();
45 
50  void Shutdown();
51 
57  void AddWindow(Window* window);
58 
64  void RemoveWindow(Window* window);
65 
71  Window* FindCorrespondingWindow(GLFWwindow* window);
72  private:
74  };
75 }
void Init()
Initializes the GLFW environment. This is to be called as one of the first steps in BlowboxCore::Run(...
Definition: glfw_manager.cc:25
GLFWManager()
Constructor for the GLFWManager.
Definition: glfw_manager.cc:13
Class for creating windows.
Definition: window.h:30
void Update()
Updates the GLFW environment. This is to be called every frame.
Definition: glfw_manager.cc:31
~GLFWManager()
Destructor for the GLFWManager.
Definition: glfw_manager.cc:19
eastl::map< Key, T > Map
Typedef for wrapping the EASTL map.
Definition: map.h:14
The core of Blowbox.
Definition: blowbox_core.h:53
void Shutdown()
Shuts down the GLFW environment. This is to be called as one of the last steps in BlowboxCore::Run() ...
Definition: glfw_manager.cc:44
Window * FindCorrespondingWindow(GLFWwindow *window)
Finds corresponding Window.
Definition: glfw_manager.cc:63
void RemoveWindow(Window *window)
Removes a Window from the GLFWManager.
Definition: glfw_manager.cc:56
The main Blowbox namespace.
Definition: image.cc:8
void AddWindow(Window *window)
Adds a Window to the GLFWManager.
Definition: glfw_manager.cc:50
Manages all GLFW state such as global initialization / termination, event polling, etc.
Definition: glfw_manager.h:16
Map< GLFWwindow *, Window * > windows_
All windows in the world.
Definition: glfw_manager.h:73