From 0898bfdf5d8e1c468a2d0aa8a3a7e320c4578dd3 Mon Sep 17 00:00:00 2001 From: gramanas Date: Fri, 24 May 2024 15:08:47 +0300 Subject: Depth buffers --- src/state.h | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'src/state.h') diff --git a/src/state.h b/src/state.h index e5cb784..2158b5b 100644 --- a/src/state.h +++ b/src/state.h @@ -100,14 +100,23 @@ typedef struct state { shaderc_compilation_result_t prev_vert_result; shaderc_compilation_result_t prev_frag_result; + + VkImage vk_texture_image; + VkDeviceMemory vk_texture_image_memory; + VkImageView vk_texture_image_view; + VkSampler vk_texture_sampler; + + VkImage vk_depth_image; + VkDeviceMemory vk_depth_image_memory; + VkImageView vk_depth_image_view; } state_t ; static void init_state(state_t * s) { - s->camera.pos[0] = 1.0f; - s->camera.pos[1] = 1.0f; - s->camera.pos[2] = 1.0f; + s->camera.pos[0] = 2.0f; + s->camera.pos[1] = 2.0f; + s->camera.pos[2] = 2.0f; s->camera.front[0] = 0.0f; s->camera.front[1] = 0.0f; -- cgit v1.2.3