From ac3118cbc54715da55856958b42817fbd1eed666 Mon Sep 17 00:00:00 2001 From: RSDuck Date: Mon, 17 Oct 2022 22:55:11 +0200 Subject: No more context mess (#1531) * WIP: use Duckstation's context code to directly render into QT Widget from separate thread without two OpenGL contexts currently only works on Windows * reenable gay OSD * add back vsync * make it atleast a little more thread safe * linux support * don't segfault on closing * reorganise and cleanup build system it's still not good, but better than before * macos? * try to get it working on Ubuntu CI also update instructions * let's try this * ok how about this * try creating an OGL 4.3 context first (https://i.kym-cdn.com/photos/images/original/001/264/842/220.png) * fix Ubuntu * hm * try again for Windows * let's try this * make the OpenGL renderer work again that was stupid * do OGL surface resizing from the mainthread * Fix small mistake in GL context creation on macOS causing version 3.2 to be considered invalid * C stupidness * cleanup * don't let the emuthread deinit OGL if there's no OGL * reset lastScreenWidth/Height when deiniting OpenGL * disable stencil test while drawing framebuffers * macOS: Link Cocoa framework explicitly when not building with Qt6 Seems to be needed for the classes used by DuckStation's GL context code. * Set ScreenPanelGL's minimum size immediately Fixes GL context creation for OpenGL display on macOS using the wrong size as the underlying window was not resized to the correct size by Qt yet. * don't emit window updates when OGL display is used * stuff Arisotura said Co-authored-by: Nadia Holmquist Pedersen --- src/PlatformOGL.h | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 src/PlatformOGL.h (limited to 'src/PlatformOGL.h') diff --git a/src/PlatformOGL.h b/src/PlatformOGL.h new file mode 100644 index 0000000..bc04780 --- /dev/null +++ b/src/PlatformOGL.h @@ -0,0 +1,9 @@ +#ifndef PLATFORMOGL_H +#define PLATFORMOGL_H + +// if you don't wanna use glad for your platform +// add your header here! + +#include "frontend/glad/glad.h" + +#endif -- cgit v1.2.3