Debian Codegraph @

Source/Core/Common/GL/GLInterface/WGL.h

raw symbols SCIP
1 // Copyright 2008 Dolphin Emulator Project
2 // SPDX-License-Identifier: GPL-2.0-or-later
3
4 #pragma once
5
6 #include <windows.h>
7 #include <string>
8 #include "Common/GL/GLContext.h"
9
10 class GLContextWGL final : public GLContext
11 {
12 public:
13 ~GLContextWGL() override;
14
15 bool IsHeadless() const override;
16
17 std::unique_ptr<GLContext> CreateSharedContext() override;
18
19 bool MakeCurrent() override;
20 bool ClearCurrent() override;
21
22 void Update() override;
23
24 void Swap() override;
25 void SwapInterval(int interval) override;
26
27 void* GetFuncAddress(const std::string& name) override;
28
29 protected:
30 bool Initialize(const WindowSystemInfo& wsi, bool stereo, bool core) override;
31
32 static HGLRC CreateCoreContext(HDC dc, HGLRC share_context);
33 static bool CreatePBuffer(HDC onscreen_dc, int width, int height, HANDLE* pbuffer_handle,
34 HDC* pbuffer_dc);
35
36 HWND m_window_handle = nullptr;
37 HANDLE m_pbuffer_handle = nullptr;
38 HDC m_dc = nullptr;
39 HGLRC m_rc = nullptr;
40 };