Files
Seele/src/Engine/Graphics/WindowManager.h
T

31 lines
537 B
C++
Raw Normal View History

#pragma once
#include "GraphicsResources.h"
2020-04-12 15:47:19 +02:00
#include "Graphics.h"
#include "Containers/Array.h"
2020-05-05 01:51:13 +02:00
#include "Window.h"
namespace Seele
{
2020-04-12 15:47:19 +02:00
class WindowManager
{
public:
WindowManager();
~WindowManager();
2020-05-05 01:51:13 +02:00
PWindow addWindow(const WindowCreateInfo &createInfo);
2020-04-12 15:47:19 +02:00
void beginFrame();
void endFrame();
2020-06-02 11:46:18 +02:00
static Gfx::PGraphics getGraphics()
2020-05-05 01:51:13 +02:00
{
return graphics;
}
2020-04-12 15:47:19 +02:00
inline bool isActive() const
{
2020-04-12 15:47:19 +02:00
return windows.size();
}
private:
2020-05-05 01:51:13 +02:00
Array<PWindow> windows;
2020-06-02 11:46:18 +02:00
static Gfx::PGraphics graphics;
2020-04-12 15:47:19 +02:00
};
DEFINE_REF(WindowManager);
} // namespace Seele