Get emulator rendering working with Qt

This commit is contained in:
wheremyfoodat 2023-10-01 01:28:08 +03:00
parent 4329976dbc
commit 5155682e0f
12 changed files with 98 additions and 22 deletions

View file

@ -67,6 +67,7 @@ class RendererGL final : public Renderer {
void setupTextureEnvState();
void bindTexturesToSlots();
void updateLightingLUT();
void initGraphicsContextInternal();
public:
RendererGL(GPU& gpu, const std::array<u32, regNum>& internalRegs, const std::array<u32, extRegNum>& externalRegs)
@ -83,6 +84,10 @@ class RendererGL final : public Renderer {
std::optional<ColourBuffer> getColourBuffer(u32 addr, PICA::ColorFmt format, u32 width, u32 height, bool createIfnotFound = true);
#ifdef PANDA3DS_FRONTEND_QT
virtual void initGraphicsContext([[maybe_unused]] GL::Context* context) override { initGraphicsContextInternal(); }
#endif
// Take a screenshot of the screen and store it in a file
void screenshot(const std::string& name) override;
};