Add OpenGLSwapChain

This commit is contained in:
2026-03-16 18:41:05 +08:00
parent fce3d2421c
commit 377f43260b
3 changed files with 60 additions and 0 deletions

View File

@@ -0,0 +1,26 @@
#pragma once
#include <GLFW/glfw3.h>
namespace XCEngine {
namespace RHI {
class OpenGLSwapChain {
public:
OpenGLSwapChain();
~OpenGLSwapChain();
bool Initialize(GLFWwindow* window);
void Shutdown();
void Present();
void SwapBuffers();
GLFWwindow* GetWindow() const { return m_window; }
private:
GLFWwindow* m_window;
};
} // namespace RHI
} // namespace XCEngine