MCPcopy Create free account
hub / github.com/defold/defold / VulkanDeleteProgram

Function VulkanDeleteProgram

engine/graphics/src/vulkan/graphics_vulkan.cpp:3596–3612  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

3594 }
3595
3596 static void VulkanDeleteProgram(HContext _context, HProgram program)
3597 {
3598 assert(program);
3599 VulkanProgram* program_ptr = (VulkanProgram*) program;
3600 VulkanContext* context = (VulkanContext*) _context;
3601
3602 DestroyProgram(_context, program_ptr);
3603
3604 DestroyShader(context, program_ptr->m_VertexModule);
3605 DestroyShader(context, program_ptr->m_FragmentModule);
3606 DestroyShader(context, program_ptr->m_ComputeModule);
3607 delete program_ptr->m_VertexModule;
3608 delete program_ptr->m_FragmentModule;
3609 delete program_ptr->m_ComputeModule;
3610
3611 delete program_ptr;
3612 }
3613
3614 static bool ReloadShader(VulkanContext* context, ShaderModule* shader, ShaderDesc::Shader* ddf, VkShaderStageFlagBits stage_flag)
3615 {

Callers

nothing calls this directly

Calls 3

DestroyShaderFunction · 0.85
DestroyProgramFunction · 0.70
assertFunction · 0.50

Tested by

no test coverage detected