From 51d0535a8d49b72ab1e47acf30f654403a94c423 Mon Sep 17 00:00:00 2001 From: omniscient <17525998+omnisci3nce@users.noreply.github.com> Date: Sat, 22 Jun 2024 15:12:44 +1000 Subject: wip: porting shadowmaps to RAL --- src/renderer/renderpasses.h | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) (limited to 'src/renderer/renderpasses.h') diff --git a/src/renderer/renderpasses.h b/src/renderer/renderpasses.h index 951ff6e..4a689e6 100644 --- a/src/renderer/renderpasses.h +++ b/src/renderer/renderpasses.h @@ -9,9 +9,7 @@ * */ #pragma once -#include "maths_types.h" #include "ral.h" -#include "render.h" #include "render_types.h" // Shadowmap pass @@ -24,5 +22,16 @@ gpu_renderpass* renderpass_blinn_phong_create(); void renderpass_blinn_phong_execute(gpu_renderpass* pass, render_entity* entities, size_t entity_count); -gpu_renderpass* renderpass_shadows_create(); -void renderpass_shadows_execute(gpu_renderpass* pass, render_entity* entities, size_t entity_count); \ No newline at end of file +typedef struct ren_shadowmaps { + u32 width; + u32 height; + gpu_renderpass* rpass; + gpu_pipeline* static_pipeline; +} ren_shadowmaps; + +void ren_shadowmaps_init(ren_shadowmaps* storage); + +gpu_renderpass* shadowmaps_renderpass_create(); +gpu_pipeline* shadowmaps_pipeline_create(); + +void renderpass_shadowmap_execute(gpu_renderpass* pass, render_entity* entities, size_t entity_count); -- cgit v1.2.3-70-g09d2