Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rename debug commands, add some new ones #1878

Merged
merged 1 commit into from
Apr 16, 2022
Merged

Conversation

Rua
Copy link
Contributor

@Rua Rua commented Apr 16, 2022

Changelog:

- **Breaking** The debug command buffer commands have been renamed to match Vulkan. They now take a `DebugUtilsLabel` value.
- **Breaking** `end_debug_utils_label` is now `unsafe`, as it requires validation checks that are not implemented yet.
- **Breaking** `DebugCallback` is renamed to `DebugUtilsMessenger` to match Vulkan, and now takes a `DebugUtilsMessengerCreateInfo` to construct. It is now `unsafe` to create, because the the callback cannot call any Vulkan API functions, which Vulkano is unable to check.
- Added debug utils commands to `Queue`.
- Added `Instance::with_debug_utils_messengers`, to provide creation info for messengers that should be used at instance creation and destruction time. This function is also `unsafe`.

Fixes #1872. This PR brings some of the debug stuff up to spec and adds a few missing features. Not everything in this extension is implemented yet, but now at least there's more of it.

Copy link
Member

@AustinJ235 AustinJ235 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

AustinJ235 added a commit that referenced this pull request Apr 16, 2022
@AustinJ235 AustinJ235 merged commit 44e3057 into vulkano-rs:master Apr 16, 2022
Rua added a commit that referenced this pull request Apr 17, 2022
@@ -15,7 +16,10 @@ use vulkano::{
format::Format,
image::{ImageDimensions, ImmutableImage, MipmapsCount},
instance::{
debug::{DebugCallback, MessageSeverity, MessageType},
debug::{
DebugUtilsMessageSeverity, DebugUtilsMessageType, DebugUtilsMessenger,
Copy link

@jherico jherico Apr 17, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The advantage of having a language with namespace support is that you can avoid the naming verbosity of the C structs. I'd argue that MessageSeverity, etc should have remained as the names.

Additionally, it leaves UserCallback as being inconsistent with the rest of the naming scheme, since it should technically be something like DebugUtilsMessengerCallback

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

No support for vk_ext_debug_utils during instance creation
3 participants