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

Method trigger_command

app/plugins/batch_mode/batch_mode.cpp:137–169  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

135}
136
137void BatchMode::trigger_command()
138{
139 sample_list = apps::get_samples(categories, tags);
140
141 if (!skips.empty())
142 {
143 std::vector<apps::AppInfo *> filtered_list;
144 filtered_list.reserve(sample_list.size() - skips.size());
145
146 std::copy_if(
147 sample_list.begin(), sample_list.end(), std::back_inserter(filtered_list), [&](const apps::AppInfo *app) { return !skips.count(app->id); });
148
149 if (filtered_list.size() != sample_list.size())
150 {
151 sample_list.swap(filtered_list);
152 }
153 }
154
155 if (sample_list.empty())
156 {
157 LOGE("No samples found")
158 throw std::runtime_error{"Can not continue"};
159 }
160
161 sample_iter = sample_list.begin();
162
163 vkb::Window::OptionalProperties properties;
164 properties.resizable = false;
165 platform->set_window_properties(properties);
166 platform->disable_input_processing();
167 platform->force_render(true);
168 request_app();
169}
170
171void BatchMode::on_update(float delta_time)
172{

Callers

nothing calls this directly

Calls 7

emptyMethod · 0.80
sizeMethod · 0.80
endMethod · 0.80
set_window_propertiesMethod · 0.80
force_renderMethod · 0.80
beginMethod · 0.45

Tested by

no test coverage detected