Renderer: Expose present mode and allow to query/set it

This commit is contained in:
SirLynix
2023-08-13 18:16:03 +02:00
parent 28d69ab552
commit e8620894f7
21 changed files with 420 additions and 43 deletions

View File

@@ -34,10 +34,12 @@ namespace Nz::GL
bool Create(const WGLContext* baseContext, const ContextParams& params, WindowHandle window, const WGLContext* shareContext = nullptr);
void Destroy();
void EnableVerticalSync(bool enabled) override;
PresentModeFlags GetSupportedPresentModes() const override;
inline bool HasPlatformExtension(const std::string& str) const;
void SetPresentMode(PresentMode presentMode) override;
void SwapBuffers() override;
WGLContext& operator=(const WGLContext&) = delete;

View File

@@ -6,7 +6,7 @@
namespace Nz::GL
{
inline GL::WGLContext::WGLContext(const OpenGLDevice* device, const WGLLoader& loader) :
inline WGLContext::WGLContext(const OpenGLDevice* device, const WGLLoader& loader) :
Context(device),
m_loader(loader),
m_handle(nullptr)