KhronosGroup / Vulkan-Samples

One stop solution for all Vulkan samples
Apache License 2.0
4.33k stars 647 forks source link

Clean up (and maybe extend) Hello Triangle sample #1168

Open SaschaWillems opened 2 months ago

SaschaWillems commented 2 months ago

I'm currently working on a hell triangle sample for Vulkan 1.3 and noticed that our existing hello triangle sample is in dire need of a code cleanup. While it works fine, there are several parts in the code that make it hard to follow. Other parts are unnecessary, variables are named badly and sometimes not even used at all. Also validation layers are not always properly enabled as only parts of the sample also use the debug define to enable them, others don't. Also some of the error messages are plainly wrong and may mislead readers.

SaschaWillems commented 2 months ago

The sample is also partially outdated and uses e.g. VK_EXT_debug_report which has long been deprecated in favor of VK_EXT_debug_utils.

SaschaWillems commented 2 months ago

I also feel the sample is lacking some crucial functionality to make it a good entry into Vulkan: