From 3b791f79bf53e481d053ea4516eedce8be3423bf Mon Sep 17 00:00:00 2001 From: Dan Goodliffe Date: Tue, 1 Nov 2022 19:12:04 +0000 Subject: Switch to a deferred lighting based render pipeline Tidy-up required. --- ui/sceneRenderer.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 ui/sceneRenderer.h (limited to 'ui/sceneRenderer.h') diff --git a/ui/sceneRenderer.h b/ui/sceneRenderer.h new file mode 100644 index 0000000..2e1c372 --- /dev/null +++ b/ui/sceneRenderer.h @@ -0,0 +1,18 @@ +#pragma once + +#include "gfx/gl/shader.h" +#include "lib/glArrays.h" +#include + +class SceneRenderer { +public: + SceneRenderer(glm::ivec2 size); + + void render(std::function content) const; + +private: + glFrameBuffer gBuffer; + glTexture gPosition, gNormal, gAlbedoSpec; + glRenderBuffer depth; + ProgramHandleBase lighting; +}; -- cgit v1.2.3