summaryrefslogtreecommitdiff
path: root/Runtime/Graphics/Device.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Runtime/Graphics/Device.cpp')
-rw-r--r--Runtime/Graphics/Device.cpp78
1 files changed, 78 insertions, 0 deletions
diff --git a/Runtime/Graphics/Device.cpp b/Runtime/Graphics/Device.cpp
new file mode 100644
index 0000000..d729a37
--- /dev/null
+++ b/Runtime/Graphics/Device.cpp
@@ -0,0 +1,78 @@
+#include "Device.h"
+
+bool deviceInited = false;
+Device g_Device;
+
+Device::Device()
+{
+ Assert(deviceInited);
+ deviceInited = true;
+}
+
+void Device::Initialize(DeviceSetting& setting)
+{
+ GPU::BufferPool::Instance()->Initialize();
+}
+
+void Device::Enable(DeviceEnable enabled)
+{
+
+}
+
+void Device::Disable(DeviceEnable enabled)
+{
+
+}
+
+void Device::IsEnable(uint flag)
+{
+
+}
+
+void Device::SetDepthTest(DepthTest testing)
+{
+
+}
+
+void Device::SetCullFace(CullFace face)
+{
+
+}
+
+void Device::SetStencilMask(byte stencilMask)
+{
+
+}
+
+void Device::SetStencilOp(StencilOp op)
+{
+
+}
+
+void Device::SetAntiAliasing(int level /*= 0*/)
+{
+
+}
+
+void Device::Clear(int clearFlag)
+{
+
+}
+
+void Device::BeginFrame()
+{
+ m_IsInsideFrame = true;
+
+}
+
+void Device::EndFrame()
+{
+ GPU::BufferPool::Instance()->OnEndFrame();
+
+ m_IsInsideFrame = false;
+}
+
+void Device::PresentFrame()
+{
+// swap buffers
+} \ No newline at end of file