Grindstone Game Engine v0.2.0
An open source game engine and toolkit.
Loading...
Searching...
No Matches
ShadowPass.hpp
1#pragma once
2
3#include <functional>
4
5#include <Common/Rendering/RenderGraph.hpp>
6#include <Common/Rendering/GeometryRenderingStats.hpp>
7#include <EngineCore/Assets/AssetReference.hpp>
8#include <EngineCore/Assets/PipelineSet/GraphicsPipelineAsset.hpp>
9
10namespace Grindstone::Renderer {
14
15
16 class ShadowPass {
17 public:
18 bool Initialize();
19 ShadowPassReturnData AddShadowPasses(
20 const glm::vec3& eyePos,
21 const glm::mat4& cameraProjectionMatrix,
22 const glm::mat4& cameraViewMatrix,
24 Grindstone::WorldContextSet& worldContextSet,
25 std::function<void(const Grindstone::Rendering::GeometryRenderStats&)> pushRenderingStatsCallback
26 );
27
28 protected:
29 void PrepareAtlas(uint32_t totalShadowMapCount);
30 bool GetAtlasRenderArea(Grindstone::Math::IntRect2D& rect);
31 uint32_t currentAtlasIndex = 0;
32 uint32_t shadowResolution = 512;
33 uint32_t maxAtlasCount = 0;
34 };
35}
Definition RenderGraphBuilder.hpp:12
Definition ShadowPass.hpp:16
Definition WorldContextSet.hpp:11
Definition AttachmentInfo.hpp:15
Definition Rect.hpp:33
Definition RenderGraphResourceRef.hpp:51
Definition ShadowPass.hpp:11
Definition GeometryRenderingStats.hpp:6