summaryrefslogtreecommitdiff
path: root/Source/Asura.Engine/Window
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Asura.Engine/Window')
-rw-r--r--Source/Asura.Engine/Window/Window.cpp39
-rw-r--r--Source/Asura.Engine/Window/Window.h16
2 files changed, 49 insertions, 6 deletions
diff --git a/Source/Asura.Engine/Window/Window.cpp b/Source/Asura.Engine/Window/Window.cpp
index 5e800e0..6e9300f 100644
--- a/Source/Asura.Engine/Window/Window.cpp
+++ b/Source/Asura.Engine/Window/Window.cpp
@@ -5,9 +5,9 @@ namespace AsuraEngine
namespace Graphics
{
- Window::Window()
+ Window::Window(WindowStyle style)
{
-
+ //mWindowHandle = SDL_CreateWindow();
}
Window::~Window()
@@ -15,5 +15,40 @@ namespace AsuraEngine
}
+ SDL_Window* Window::GetSDLWindowHandle()
+ {
+ return mWindowHandle;
+ }
+
+ void Window::SetPosition(int x, int y)
+ {
+
+ }
+
+ void Window::SetTitle(const std::string& title)
+ {
+
+ }
+
+ void Window::Show()
+ {
+
+ }
+
+ void Window::Hide()
+ {
+
+ }
+
+ void Window::SetWindowStyle(WindowStyle style)
+ {
+
+ }
+
+ void Window::SwapRenderBuffer()
+ {
+
+ }
+
}
}
diff --git a/Source/Asura.Engine/Window/Window.h b/Source/Asura.Engine/Window/Window.h
index 3456d75..71aaf0e 100644
--- a/Source/Asura.Engine/Window/Window.h
+++ b/Source/Asura.Engine/Window/Window.h
@@ -12,21 +12,21 @@ namespace AsuraEngine
enum WindowStyle
{
-
+ WINDOW_STYLE_FULLSCREEN = 1 << 1,
};
///
/// ڣֶ֧രڡڱ༭Ҫ֧֣runnerֻҪһڡ
///
- class Window final : public RenderTarget
+ class Window : public RenderTarget
{
public:
- Window();
+ Window(WindowStyle style);
~Window();
- SDL_Window* GetSDLHandle();
+ SDL_Window* GetSDLWindowHandle();
void SetSize(uint width, uint height);
@@ -45,6 +45,14 @@ namespace AsuraEngine
///
void SwapRenderBuffer();
+ void Clear(const Color& col = Color::Black);
+
+ void Clear(const Math::Recti& quad, const Color& col = Color::Black);
+
+ void Draw(const Drawable* texture, const RenderState& state);
+
+ void Draw(const Drawable* texture, const Math::Recti& quad, const RenderState& state);
+
private:
///