Renderer: Improve null renderer performance

This commit is contained in:
wheremyfoodat 2024-11-24 17:36:57 +02:00
parent 04d047ff75
commit a14eaf9d1c
2 changed files with 9 additions and 5 deletions

View file

@ -17,6 +17,10 @@ class RendererNull final : public Renderer {
void screenshot(const std::string& name) override;
void deinitGraphicsContext() override;
// Tell the GPU core that we'll handle vertex fetch & shader execution in the renderer in order to speed up execution.
// Of course, we don't do this and geometry is never actually processed, since this is the null renderer.
virtual bool prepareForDraw(ShaderUnit& shaderUnit, PICA::DrawAcceleration* accel) override { return true; };
#ifdef PANDA3DS_FRONTEND_QT
virtual void initGraphicsContext([[maybe_unused]] GL::Context* context) override {}
#endif