MCPcopy Create free account
hub / github.com/KhronosGroup/Vulkan-Samples / prepare_gui

Method prepare_gui

framework/hpp_api_vulkan_sample.cpp:71–89  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

69}
70
71void HPPApiVulkanSample::prepare_gui()
72{
73 create_gui(*window, nullptr, 15.0f, true);
74
75 std::vector<vk::PipelineShaderStageCreateInfo> shader_stages = {
76 load_shader("uioverlay/uioverlay.vert.spv", vk::ShaderStageFlagBits::eVertex),
77 load_shader("uioverlay/uioverlay.frag.spv", vk::ShaderStageFlagBits::eFragment)};
78
79 if (uses_dynamic_rendering())
80 {
81 vk::Format color_format = get_render_context().get_swapchain().get_format();
82 vk::Format depth_fmt = vk::Format::eUndefined;
83 get_gui().prepare(pipeline_cache, color_format, depth_fmt, shader_stages);
84 }
85 else
86 {
87 get_gui().prepare(pipeline_cache, render_pass, shader_stages, get_gui_subpass());
88 }
89}
90
91void HPPApiVulkanSample::update(float delta_time)
92{

Callers

nothing calls this directly

Calls 3

load_shaderFunction · 0.50
get_formatMethod · 0.45
prepareMethod · 0.45

Tested by

no test coverage detected