Vulkan-Samples
Vulkan-Samples copied to clipboard
Small batch mode fixes
Description
A series of small batch mode fixes that i found when running batch mode. This does not fix validation errors but does fix segfaults / assertions.
Added force_render
which allows batch mode to override the update if focused
functionality so that you can multi task whilst running batch mode in the background.
Tested on Linux. Samples may still have existing issues on other platforms
General Checklist:
Please ensure the following points are checked:
- [x] My code follows the coding style
- [x] I have reviewed file licenses
- [x] I have commented any added functions (in line with Doxygen)
- [x] I have commented any code that could be hard to understand
- [x] My changes do not add any new compiler warnings
- [x] My changes do not add any new validation layer errors or warnings
- [x] I have used existing framework/helper functions where possible
- [x] My changes do not add any regressions
- [x] I have tested every sample to ensure everything runs correctly
- [x] This PR describes the scope and expected impact of the changes I am making
Note: The Samples CI runs a number of checks including:
- [x] I have updated the header Copyright to reflect the current year (CI build will fail if Copyright is out of date)
- [x] My changes build on Windows, Linux, macOS and Android. Otherwise I have documented any exceptions
If this PR contains framework changes:
- [x] I did a full batch run using the
batch
command line argument to make sure all samples still work properly
Aside from gary's comment this looks fine. This will be very useful for maintainers, esp. being able to have the batch run continue when inactive. That way I can finally run it on my second screen while doing other stuff 👍🏻
@tomadamatkinson: Are you able to fix what Gary noted? Getting those fixes merged would make future PRs a lot easier. If you can't find the time for that, I'm happy to jump in :)
@SaschaWillems @gary-sweet this should be resolved now!
Awesome. Thank you very much :)
I'm still seeing some odd display in command_buffer_usage sadly:
@gary-sweet thats a weird one...
Just to check, you've pulled the up to date version of the branch. I did rebase on main.
Do you see this behaviour with any other sliders? The slider I changed is now inline with the other slider usage
Just to check, you've pulled the up to date version of the branch. I did rebase on main.
Yes
Do you see this behaviour with any other sliders? The slider I changed is now inline with the other slider usage
Well, if I run command_buffer_usage on main, I just get:
vulkan_samples: third_party/imgui/imgui.cpp:9907: bool ImGui::ItemAdd(const ImRect&, ImGuiID, const ImRect*, ImGuiItemFlags): Assertion 'id != window->ID && "Cannot have an empty ID at the root of a window. If you need an empty label, use ## and read the FAQ about how the ID Stack works!"' failed.
All the other sliders appear to have the label to the right of them (which I think is how they're supposed to be looking at the screenshots from those samples).
Interesting, I'll take another look!
Interesting, I'll take another look!
Changing the slider code in command_buffer_usage.cpp to:
ImGui::SliderInt("##secCmdBufs", &gui_secondary_cmd_buf_count, 0, max_secondary_command_buffer_count, "Secondary CmdBuffs: %d");
solves the problem for me. The ##secCmdBufs
ensures there is a unique ID associated with the slider, and the %d then starts working.
Ah it was an issue with my setup. Looks like the binary path to Vulkan Samples has now changed on MacOS. My run command was pointing at an older version 🤦