From 8acb4a0aad7f4d1b2438010d487489a9641e30cb Mon Sep 17 00:00:00 2001 From: Frederico Linhares Date: Sat, 23 Mar 2024 19:05:26 -0300 Subject: fixt Make skeletal mesh work properly --- src/vk/device.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/vk/device.cpp') diff --git a/src/vk/device.cpp b/src/vk/device.cpp index d0690d7..78baa53 100644 --- a/src/vk/device.cpp +++ b/src/vk/device.cpp @@ -203,6 +203,12 @@ Device::Device(VkPhysicalDevice vk_physical_device, bool with_swapchain) this->vert3d_shader_module = create_shader_module( this->device, vert3d_shader_module.c_str()); + std::string vert3d_skeletal_shader_module{data_dir}; + vert3d_skeletal_shader_module.append( + "\\glsl\\shader_3d_skeletal.vert.spv"); + this->vert3d_skeletal_shader_module = create_shader_module( + this->device, vert3d_skeletal_shader_module.c_str()); + std::string frag3d_shader_module{data_dir}; frag3d_shader_module.append("\\glsl\\shader_3d.frag.spv"); this->frag3d_shader_module = create_shader_module( @@ -245,6 +251,11 @@ Device::Device(VkPhysicalDevice vk_physical_device, bool with_swapchain) this->vert3d_shader_module = create_shader_module( this->device, vert3d_shader_module.c_str()); + std::string vert3d_skeletal_shader_module{data_dir}; + vert3d_skeletal_shader_module.append("/glsl/shader_3d_skeletal.vert.spv"); + this->vert3d_skeletal_shader_module = create_shader_module( + this->device, vert3d_skeletal_shader_module.c_str()); + std::string frag3d_shader_module{data_dir}; frag3d_shader_module.append("/glsl/shader_3d.frag.spv"); this->frag3d_shader_module = create_shader_module( @@ -308,6 +319,8 @@ Device::~Device() vkDestroyShaderModule( this->device, this->frag_sprite_3d_shader_module, nullptr); vkDestroyShaderModule(this->device, this->vert3d_shader_module, nullptr); + vkDestroyShaderModule( + this->device, this->vert3d_skeletal_shader_module, nullptr); vkDestroyShaderModule(this->device, this->frag3d_shader_module, nullptr); vkDestroyShaderModule( this->device, this->vert2d_solid_shader_module, nullptr); -- cgit v1.2.3