From 2b47879b0143812fb84d2330ff071ea327e04e20 Mon Sep 17 00:00:00 2001 From: Marijn Suijten Date: Thu, 26 Sep 2024 11:08:30 +0200 Subject: [PATCH] Update Vulkan-Headers to 1.3.296 --- Changelog.md | 2 +- ash/Cargo.toml | 2 +- ash/src/extensions_generated.rs | 340 +++++++++ ash/src/vk/bitflags.rs | 18 + ash/src/vk/const_debugs.rs | 140 ++++ ash/src/vk/definitions.rs | 1185 ++++++++++++++++++++++++++++++- ash/src/vk/enums.rs | 64 ++ ash/src/vk/extensions.rs | 140 ++++ generator/Vulkan-Headers | 2 +- 9 files changed, 1889 insertions(+), 4 deletions(-) diff --git a/Changelog.md b/Changelog.md index b26e4eb63..25c0beb62 100644 --- a/Changelog.md +++ b/Changelog.md @@ -9,7 +9,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added -- Update Vulkan-Headers to 1.3.295 (#910) +- Update Vulkan-Headers to 1.3.296 (#910) - Added `VK_EXT_metal_objects` device extension (#942) ## [0.38.0] - 2024-04-01 diff --git a/ash/Cargo.toml b/ash/Cargo.toml index 2c1b3a150..f0400b0a7 100644 --- a/ash/Cargo.toml +++ b/ash/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ash" -version = "0.38.0+1.3.295" +version = "0.38.0+1.3.296" authors = [ "Maik Klein ", "Benjamin Saunders ", diff --git a/ash/src/extensions_generated.rs b/ash/src/extensions_generated.rs index 57c073773..7e2a4affc 100644 --- a/ash/src/extensions_generated.rs +++ b/ash/src/extensions_generated.rs @@ -7312,6 +7312,7 @@ pub mod ext { pub cmd_set_representative_fragment_test_enable_nv: PFN_vkCmdSetRepresentativeFragmentTestEnableNV, pub cmd_set_coverage_reduction_mode_nv: PFN_vkCmdSetCoverageReductionModeNV, + pub cmd_set_depth_clamp_range_ext: PFN_vkCmdSetDepthClampRangeEXT, } unsafe impl Send for DeviceFn {} unsafe impl Sync for DeviceFn {} @@ -8364,6 +8365,26 @@ pub mod ext { ::core::mem::transmute(val) } }, + cmd_set_depth_clamp_range_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_clamp_range_ext( + _command_buffer: CommandBuffer, + _depth_clamp_mode: DepthClampModeEXT, + _p_depth_clamp_range: *const DepthClampRangeEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_clamp_range_ext) + )) + } + let cname = + CStr::from_bytes_with_nul_unchecked(b"vkCmdSetDepthClampRangeEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_clamp_range_ext + } else { + ::core::mem::transmute(val) + } + }, } } } @@ -8484,6 +8505,325 @@ pub mod ext { crate::vk::EXT_SHADER_REPLICATED_COMPOSITES_SPEC_VERSION as SPEC_VERSION, }; } + #[doc = "VK_EXT_device_generated_commands"] + pub mod device_generated_commands { + use super::super::*; + pub use { + crate::vk::EXT_DEVICE_GENERATED_COMMANDS_NAME as NAME, + crate::vk::EXT_DEVICE_GENERATED_COMMANDS_SPEC_VERSION as SPEC_VERSION, + }; + #[doc = "VK_EXT_device_generated_commands device-level functions"] + #[derive(Clone)] + pub struct Device { + pub(crate) fp: DeviceFn, + pub(crate) handle: crate::vk::Device, + } + impl Device { + pub fn new(instance: &crate::Instance, device: &crate::Device) -> Self { + let handle = device.handle(); + let fp = DeviceFn::load(|name| unsafe { + core::mem::transmute(instance.get_device_proc_addr(handle, name.as_ptr())) + }); + Self { handle, fp } + } + #[inline] + pub fn fp(&self) -> &DeviceFn { + &self.fp + } + #[inline] + pub fn device(&self) -> crate::vk::Device { + self.handle + } + } + #[derive(Clone)] + #[doc = "Raw VK_EXT_device_generated_commands device-level function pointers"] + pub struct DeviceFn { + pub get_generated_commands_memory_requirements_ext: + PFN_vkGetGeneratedCommandsMemoryRequirementsEXT, + pub cmd_preprocess_generated_commands_ext: PFN_vkCmdPreprocessGeneratedCommandsEXT, + pub cmd_execute_generated_commands_ext: PFN_vkCmdExecuteGeneratedCommandsEXT, + pub create_indirect_commands_layout_ext: PFN_vkCreateIndirectCommandsLayoutEXT, + pub destroy_indirect_commands_layout_ext: PFN_vkDestroyIndirectCommandsLayoutEXT, + pub create_indirect_execution_set_ext: PFN_vkCreateIndirectExecutionSetEXT, + pub destroy_indirect_execution_set_ext: PFN_vkDestroyIndirectExecutionSetEXT, + pub update_indirect_execution_set_pipeline_ext: + PFN_vkUpdateIndirectExecutionSetPipelineEXT, + pub update_indirect_execution_set_shader_ext: PFN_vkUpdateIndirectExecutionSetShaderEXT, + } + unsafe impl Send for DeviceFn {} + unsafe impl Sync for DeviceFn {} + impl DeviceFn { + pub fn load *const c_void>(mut f: F) -> Self { + Self::load_erased(&mut f) + } + fn load_erased(_f: &mut dyn FnMut(&CStr) -> *const c_void) -> Self { + Self { + get_generated_commands_memory_requirements_ext: unsafe { + unsafe extern "system" fn get_generated_commands_memory_requirements_ext( + _device: crate::vk::Device, + _p_info: *const GeneratedCommandsMemoryRequirementsInfoEXT<'_>, + _p_memory_requirements: *mut MemoryRequirements2<'_>, + ) { + panic!(concat!( + "Unable to load ", + stringify!(get_generated_commands_memory_requirements_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkGetGeneratedCommandsMemoryRequirementsEXT\0", + ); + let val = _f(cname); + if val.is_null() { + get_generated_commands_memory_requirements_ext + } else { + ::core::mem::transmute(val) + } + }, + cmd_preprocess_generated_commands_ext: unsafe { + unsafe extern "system" fn cmd_preprocess_generated_commands_ext( + _command_buffer: CommandBuffer, + _p_generated_commands_info: *const GeneratedCommandsInfoEXT<'_>, + _state_command_buffer: CommandBuffer, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_preprocess_generated_commands_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkCmdPreprocessGeneratedCommandsEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_preprocess_generated_commands_ext + } else { + ::core::mem::transmute(val) + } + }, + cmd_execute_generated_commands_ext: unsafe { + unsafe extern "system" fn cmd_execute_generated_commands_ext( + _command_buffer: CommandBuffer, + _is_preprocessed: Bool32, + _p_generated_commands_info: *const GeneratedCommandsInfoEXT<'_>, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_execute_generated_commands_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkCmdExecuteGeneratedCommandsEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_execute_generated_commands_ext + } else { + ::core::mem::transmute(val) + } + }, + create_indirect_commands_layout_ext: unsafe { + unsafe extern "system" fn create_indirect_commands_layout_ext( + _device: crate::vk::Device, + _p_create_info: *const IndirectCommandsLayoutCreateInfoEXT<'_>, + _p_allocator: *const AllocationCallbacks<'_>, + _p_indirect_commands_layout: *mut IndirectCommandsLayoutEXT, + ) -> Result { + panic!(concat!( + "Unable to load ", + stringify!(create_indirect_commands_layout_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkCreateIndirectCommandsLayoutEXT\0", + ); + let val = _f(cname); + if val.is_null() { + create_indirect_commands_layout_ext + } else { + ::core::mem::transmute(val) + } + }, + destroy_indirect_commands_layout_ext: unsafe { + unsafe extern "system" fn destroy_indirect_commands_layout_ext( + _device: crate::vk::Device, + _indirect_commands_layout: IndirectCommandsLayoutEXT, + _p_allocator: *const AllocationCallbacks<'_>, + ) { + panic!(concat!( + "Unable to load ", + stringify!(destroy_indirect_commands_layout_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkDestroyIndirectCommandsLayoutEXT\0", + ); + let val = _f(cname); + if val.is_null() { + destroy_indirect_commands_layout_ext + } else { + ::core::mem::transmute(val) + } + }, + create_indirect_execution_set_ext: unsafe { + unsafe extern "system" fn create_indirect_execution_set_ext( + _device: crate::vk::Device, + _p_create_info: *const IndirectExecutionSetCreateInfoEXT<'_>, + _p_allocator: *const AllocationCallbacks<'_>, + _p_indirect_execution_set: *mut IndirectExecutionSetEXT, + ) -> Result { + panic!(concat!( + "Unable to load ", + stringify!(create_indirect_execution_set_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkCreateIndirectExecutionSetEXT\0", + ); + let val = _f(cname); + if val.is_null() { + create_indirect_execution_set_ext + } else { + ::core::mem::transmute(val) + } + }, + destroy_indirect_execution_set_ext: unsafe { + unsafe extern "system" fn destroy_indirect_execution_set_ext( + _device: crate::vk::Device, + _indirect_execution_set: IndirectExecutionSetEXT, + _p_allocator: *const AllocationCallbacks<'_>, + ) { + panic!(concat!( + "Unable to load ", + stringify!(destroy_indirect_execution_set_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkDestroyIndirectExecutionSetEXT\0", + ); + let val = _f(cname); + if val.is_null() { + destroy_indirect_execution_set_ext + } else { + ::core::mem::transmute(val) + } + }, + update_indirect_execution_set_pipeline_ext: unsafe { + unsafe extern "system" fn update_indirect_execution_set_pipeline_ext( + _device: crate::vk::Device, + _indirect_execution_set: IndirectExecutionSetEXT, + _execution_set_write_count: u32, + _p_execution_set_writes: *const WriteIndirectExecutionSetPipelineEXT< + '_, + >, + ) { + panic!(concat!( + "Unable to load ", + stringify!(update_indirect_execution_set_pipeline_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkUpdateIndirectExecutionSetPipelineEXT\0", + ); + let val = _f(cname); + if val.is_null() { + update_indirect_execution_set_pipeline_ext + } else { + ::core::mem::transmute(val) + } + }, + update_indirect_execution_set_shader_ext: unsafe { + unsafe extern "system" fn update_indirect_execution_set_shader_ext( + _device: crate::vk::Device, + _indirect_execution_set: IndirectExecutionSetEXT, + _execution_set_write_count: u32, + _p_execution_set_writes: *const WriteIndirectExecutionSetShaderEXT<'_>, + ) { + panic!(concat!( + "Unable to load ", + stringify!(update_indirect_execution_set_shader_ext) + )) + } + let cname = CStr::from_bytes_with_nul_unchecked( + b"vkUpdateIndirectExecutionSetShaderEXT\0", + ); + let val = _f(cname); + if val.is_null() { + update_indirect_execution_set_shader_ext + } else { + ::core::mem::transmute(val) + } + }, + } + } + } + } + #[doc = "VK_EXT_depth_clamp_control"] + pub mod depth_clamp_control { + use super::super::*; + pub use { + crate::vk::EXT_DEPTH_CLAMP_CONTROL_NAME as NAME, + crate::vk::EXT_DEPTH_CLAMP_CONTROL_SPEC_VERSION as SPEC_VERSION, + }; + #[doc = "VK_EXT_depth_clamp_control device-level functions"] + #[derive(Clone)] + pub struct Device { + pub(crate) fp: DeviceFn, + pub(crate) handle: crate::vk::Device, + } + impl Device { + pub fn new(instance: &crate::Instance, device: &crate::Device) -> Self { + let handle = device.handle(); + let fp = DeviceFn::load(|name| unsafe { + core::mem::transmute(instance.get_device_proc_addr(handle, name.as_ptr())) + }); + Self { handle, fp } + } + #[inline] + pub fn fp(&self) -> &DeviceFn { + &self.fp + } + #[inline] + pub fn device(&self) -> crate::vk::Device { + self.handle + } + } + #[derive(Clone)] + #[doc = "Raw VK_EXT_depth_clamp_control device-level function pointers"] + pub struct DeviceFn { + pub cmd_set_depth_clamp_range_ext: PFN_vkCmdSetDepthClampRangeEXT, + } + unsafe impl Send for DeviceFn {} + unsafe impl Sync for DeviceFn {} + impl DeviceFn { + pub fn load *const c_void>(mut f: F) -> Self { + Self::load_erased(&mut f) + } + fn load_erased(_f: &mut dyn FnMut(&CStr) -> *const c_void) -> Self { + Self { + cmd_set_depth_clamp_range_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_clamp_range_ext( + _command_buffer: CommandBuffer, + _depth_clamp_mode: DepthClampModeEXT, + _p_depth_clamp_range: *const DepthClampRangeEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_clamp_range_ext) + )) + } + let cname = + CStr::from_bytes_with_nul_unchecked(b"vkCmdSetDepthClampRangeEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_clamp_range_ext + } else { + ::core::mem::transmute(val) + } + }, + } + } + } + } } #[doc = "Extensions tagged FUCHSIA"] pub mod fuchsia { diff --git a/ash/src/vk/bitflags.rs b/ash/src/vk/bitflags.rs index 6181f3953..c2f24094a 100644 --- a/ash/src/vk/bitflags.rs +++ b/ash/src/vk/bitflags.rs @@ -1724,6 +1724,24 @@ impl MicromapCreateFlagsEXT { } #[repr(transparent)] #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] +#[doc = ""] +pub struct IndirectCommandsLayoutUsageFlagsEXT(pub(crate) Flags); +vk_bitflags_wrapped!(IndirectCommandsLayoutUsageFlagsEXT, Flags); +impl IndirectCommandsLayoutUsageFlagsEXT { + pub const EXPLICIT_PREPROCESS: Self = Self(0b1); + pub const UNORDERED_SEQUENCES: Self = Self(0b10); +} +#[repr(transparent)] +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] +#[doc = ""] +pub struct IndirectCommandsInputModeFlagsEXT(pub(crate) Flags); +vk_bitflags_wrapped!(IndirectCommandsInputModeFlagsEXT, Flags); +impl IndirectCommandsInputModeFlagsEXT { + pub const VULKAN_INDEX_BUFFER: Self = Self(0b1); + pub const DXGI_INDEX_BUFFER: Self = Self(0b10); +} +#[repr(transparent)] +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] #[doc = ""] pub struct ShaderCreateFlagsEXT(pub(crate) Flags); vk_bitflags_wrapped!(ShaderCreateFlagsEXT, Flags); diff --git a/ash/src/vk/const_debugs.rs b/ash/src/vk/const_debugs.rs index aeb8e0ebf..b0d032397 100644 --- a/ash/src/vk/const_debugs.rs +++ b/ash/src/vk/const_debugs.rs @@ -734,6 +734,10 @@ impl fmt::Debug for BufferUsageFlags2KHR { BufferUsageFlags2KHR::MICROMAP_STORAGE_EXT.0, "MICROMAP_STORAGE_EXT", ), + ( + BufferUsageFlags2KHR::PREPROCESS_BUFFER_EXT.0, + "PREPROCESS_BUFFER_EXT", + ), ]; debug_flags(f, KNOWN, self.0) } @@ -1294,6 +1298,20 @@ impl fmt::Debug for DepthBiasRepresentationEXT { } } } +impl fmt::Debug for DepthClampModeEXT { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + let name = match *self { + Self::VIEWPORT_RANGE => Some("VIEWPORT_RANGE"), + Self::USER_DEFINED_RANGE => Some("USER_DEFINED_RANGE"), + _ => None, + }; + if let Some(x) = name { + f.write_str(x) + } else { + self.0.fmt(f) + } + } +} impl fmt::Debug for DescriptorBindingFlags { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { const KNOWN: &[(Flags, &str)] = &[ @@ -1788,6 +1806,7 @@ impl fmt::Debug for DynamicState { Some("ATTACHMENT_FEEDBACK_LOOP_ENABLE_EXT") } Self::LINE_STIPPLE_KHR => Some("LINE_STIPPLE_KHR"), + Self::DEPTH_CLAMP_RANGE_EXT => Some("DEPTH_CLAMP_RANGE_EXT"), Self::CULL_MODE => Some("CULL_MODE"), Self::FRONT_FACE => Some("FRONT_FACE"), Self::PRIMITIVE_TOPOLOGY => Some("PRIMITIVE_TOPOLOGY"), @@ -2941,6 +2960,36 @@ impl fmt::Debug for IndexType { } } } +impl fmt::Debug for IndirectCommandsInputModeFlagsEXT { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + const KNOWN: &[(Flags, &str)] = &[ + ( + IndirectCommandsInputModeFlagsEXT::VULKAN_INDEX_BUFFER.0, + "VULKAN_INDEX_BUFFER", + ), + ( + IndirectCommandsInputModeFlagsEXT::DXGI_INDEX_BUFFER.0, + "DXGI_INDEX_BUFFER", + ), + ]; + debug_flags(f, KNOWN, self.0) + } +} +impl fmt::Debug for IndirectCommandsLayoutUsageFlagsEXT { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + const KNOWN: &[(Flags, &str)] = &[ + ( + IndirectCommandsLayoutUsageFlagsEXT::EXPLICIT_PREPROCESS.0, + "EXPLICIT_PREPROCESS", + ), + ( + IndirectCommandsLayoutUsageFlagsEXT::UNORDERED_SEQUENCES.0, + "UNORDERED_SEQUENCES", + ), + ]; + debug_flags(f, KNOWN, self.0) + } +} impl fmt::Debug for IndirectCommandsLayoutUsageFlagsNV { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { const KNOWN: &[(Flags, &str)] = &[ @@ -2960,6 +3009,33 @@ impl fmt::Debug for IndirectCommandsLayoutUsageFlagsNV { debug_flags(f, KNOWN, self.0) } } +impl fmt::Debug for IndirectCommandsTokenTypeEXT { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + let name = match *self { + Self::EXECUTION_SET => Some("EXECUTION_SET"), + Self::PUSH_CONSTANT => Some("PUSH_CONSTANT"), + Self::SEQUENCE_INDEX => Some("SEQUENCE_INDEX"), + Self::INDEX_BUFFER => Some("INDEX_BUFFER"), + Self::VERTEX_BUFFER => Some("VERTEX_BUFFER"), + Self::DRAW_INDEXED => Some("DRAW_INDEXED"), + Self::DRAW => Some("DRAW"), + Self::DRAW_INDEXED_COUNT => Some("DRAW_INDEXED_COUNT"), + Self::DRAW_COUNT => Some("DRAW_COUNT"), + Self::DISPATCH => Some("DISPATCH"), + Self::DRAW_MESH_TASKS_NV => Some("DRAW_MESH_TASKS_NV"), + Self::DRAW_MESH_TASKS_COUNT_NV => Some("DRAW_MESH_TASKS_COUNT_NV"), + Self::DRAW_MESH_TASKS => Some("DRAW_MESH_TASKS"), + Self::DRAW_MESH_TASKS_COUNT => Some("DRAW_MESH_TASKS_COUNT"), + Self::TRACE_RAYS2 => Some("TRACE_RAYS2"), + _ => None, + }; + if let Some(x) = name { + f.write_str(x) + } else { + self.0.fmt(f) + } + } +} impl fmt::Debug for IndirectCommandsTokenTypeNV { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { let name = match *self { @@ -2983,6 +3059,20 @@ impl fmt::Debug for IndirectCommandsTokenTypeNV { } } } +impl fmt::Debug for IndirectExecutionSetInfoTypeEXT { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + let name = match *self { + Self::PIPELINES => Some("PIPELINES"), + Self::SHADER_OBJECTS => Some("SHADER_OBJECTS"), + _ => None, + }; + if let Some(x) = name { + f.write_str(x) + } else { + self.0.fmt(f) + } + } +} impl fmt::Debug for IndirectStateFlagsNV { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { const KNOWN: &[(Flags, &str)] = @@ -3870,6 +3960,10 @@ impl fmt::Debug for PipelineCreateFlags2KHR { "DESCRIPTOR_BUFFER_EXT", ), (PipelineCreateFlags2KHR::CAPTURE_DATA.0, "CAPTURE_DATA"), + ( + PipelineCreateFlags2KHR::INDIRECT_BINDABLE_EXT.0, + "INDIRECT_BINDABLE_EXT", + ), ]; debug_flags(f, KNOWN, self.0) } @@ -4810,6 +4904,10 @@ impl fmt::Debug for ShaderCreateFlagsEXT { ShaderCreateFlagsEXT::FRAGMENT_DENSITY_MAP_ATTACHMENT.0, "FRAGMENT_DENSITY_MAP_ATTACHMENT", ), + ( + ShaderCreateFlagsEXT::INDIRECT_BINDABLE.0, + "INDIRECT_BINDABLE", + ), ]; debug_flags(f, KNOWN, self.0) } @@ -6722,6 +6820,42 @@ impl fmt::Debug for StructureType { Self::PHYSICAL_DEVICE_RAY_TRACING_VALIDATION_FEATURES_NV => { Some("PHYSICAL_DEVICE_RAY_TRACING_VALIDATION_FEATURES_NV") } + Self::PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_EXT => { + Some("PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_EXT") + } + Self::PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_EXT => { + Some("PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_EXT") + } + Self::GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_EXT => { + Some("GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_EXT") + } + Self::INDIRECT_EXECUTION_SET_CREATE_INFO_EXT => { + Some("INDIRECT_EXECUTION_SET_CREATE_INFO_EXT") + } + Self::GENERATED_COMMANDS_INFO_EXT => Some("GENERATED_COMMANDS_INFO_EXT"), + Self::INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_EXT => { + Some("INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_EXT") + } + Self::INDIRECT_COMMANDS_LAYOUT_TOKEN_EXT => Some("INDIRECT_COMMANDS_LAYOUT_TOKEN_EXT"), + Self::WRITE_INDIRECT_EXECUTION_SET_PIPELINE_EXT => { + Some("WRITE_INDIRECT_EXECUTION_SET_PIPELINE_EXT") + } + Self::WRITE_INDIRECT_EXECUTION_SET_SHADER_EXT => { + Some("WRITE_INDIRECT_EXECUTION_SET_SHADER_EXT") + } + Self::INDIRECT_EXECUTION_SET_PIPELINE_INFO_EXT => { + Some("INDIRECT_EXECUTION_SET_PIPELINE_INFO_EXT") + } + Self::INDIRECT_EXECUTION_SET_SHADER_INFO_EXT => { + Some("INDIRECT_EXECUTION_SET_SHADER_INFO_EXT") + } + Self::INDIRECT_EXECUTION_SET_SHADER_LAYOUT_INFO_EXT => { + Some("INDIRECT_EXECUTION_SET_SHADER_LAYOUT_INFO_EXT") + } + Self::GENERATED_COMMANDS_PIPELINE_INFO_EXT => { + Some("GENERATED_COMMANDS_PIPELINE_INFO_EXT") + } + Self::GENERATED_COMMANDS_SHADER_INFO_EXT => Some("GENERATED_COMMANDS_SHADER_INFO_EXT"), Self::PHYSICAL_DEVICE_IMAGE_ALIGNMENT_CONTROL_FEATURES_MESA => { Some("PHYSICAL_DEVICE_IMAGE_ALIGNMENT_CONTROL_FEATURES_MESA") } @@ -6731,6 +6865,12 @@ impl fmt::Debug for StructureType { Self::IMAGE_ALIGNMENT_CONTROL_CREATE_INFO_MESA => { Some("IMAGE_ALIGNMENT_CONTROL_CREATE_INFO_MESA") } + Self::PHYSICAL_DEVICE_DEPTH_CLAMP_CONTROL_FEATURES_EXT => { + Some("PHYSICAL_DEVICE_DEPTH_CLAMP_CONTROL_FEATURES_EXT") + } + Self::PIPELINE_VIEWPORT_DEPTH_CLAMP_CONTROL_CREATE_INFO_EXT => { + Some("PIPELINE_VIEWPORT_DEPTH_CLAMP_CONTROL_CREATE_INFO_EXT") + } Self::PHYSICAL_DEVICE_SUBGROUP_PROPERTIES => { Some("PHYSICAL_DEVICE_SUBGROUP_PROPERTIES") } diff --git a/ash/src/vk/definitions.rs b/ash/src/vk/definitions.rs index a1ccf4176..8ea977a51 100644 --- a/ash/src/vk/definitions.rs +++ b/ash/src/vk/definitions.rs @@ -58,7 +58,7 @@ pub const API_VERSION_1_2: u32 = make_api_version(0, 1, 2, 0); #[doc = ""] pub const API_VERSION_1_3: u32 = make_api_version(0, 1, 3, 0); #[doc = ""] -pub const HEADER_VERSION: u32 = 295; +pub const HEADER_VERSION: u32 = 296; #[doc = ""] pub const HEADER_VERSION_COMPLETE: u32 = make_api_version(0, 1, 3, HEADER_VERSION); #[doc = ""] @@ -442,6 +442,8 @@ handle_nondispatchable!( ); handle_nondispatchable ! (PipelineBinaryKHR , PIPELINE_BINARY_KHR , doc = "") ; handle_nondispatchable ! (IndirectCommandsLayoutNV , INDIRECT_COMMANDS_LAYOUT_NV , doc = "") ; +handle_nondispatchable ! (IndirectCommandsLayoutEXT , INDIRECT_COMMANDS_LAYOUT_EXT , doc = "") ; +handle_nondispatchable ! (IndirectExecutionSetEXT , INDIRECT_EXECUTION_SET_EXT , doc = "") ; handle_nondispatchable ! (DescriptorUpdateTemplate , DESCRIPTOR_UPDATE_TEMPLATE , doc = "") ; handle_nondispatchable ! (SamplerYcbcrConversion , SAMPLER_YCBCR_CONVERSION , doc = "") ; handle_nondispatchable ! (ValidationCacheEXT , VALIDATION_CACHE_EXT , doc = "") ; @@ -5646,6 +5648,7 @@ unsafe impl ExtendsPushDescriptorSetInfoKHR for PipelineLayoutCreateInfo<'_> {} unsafe impl ExtendsPushDescriptorSetWithTemplateInfoKHR for PipelineLayoutCreateInfo<'_> {} unsafe impl ExtendsSetDescriptorBufferOffsetsInfoEXT for PipelineLayoutCreateInfo<'_> {} unsafe impl ExtendsBindDescriptorBufferEmbeddedSamplersInfoEXT for PipelineLayoutCreateInfo<'_> {} +unsafe impl ExtendsIndirectCommandsLayoutCreateInfoEXT for PipelineLayoutCreateInfo<'_> {} impl<'a> PipelineLayoutCreateInfo<'a> { #[inline] pub fn flags(mut self, flags: PipelineLayoutCreateFlags) -> Self { @@ -38434,6 +38437,1082 @@ impl<'a> PhysicalDeviceDepthClipControlFeaturesEXT<'a> { #[repr(C)] #[cfg_attr(feature = "debug", derive(Debug))] #[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub device_generated_commands: Bool32, + pub dynamic_generated_pipeline_layout: Bool32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'_> {} +unsafe impl Sync for PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'_> {} +impl ::core::default::Default for PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null_mut(), + device_generated_commands: Bool32::default(), + dynamic_generated_pipeline_layout: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_EXT; +} +unsafe impl ExtendsPhysicalDeviceFeatures2 + for PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'_> +{ +} +unsafe impl ExtendsDeviceCreateInfo for PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'_> {} +impl<'a> PhysicalDeviceDeviceGeneratedCommandsFeaturesEXT<'a> { + #[inline] + pub fn device_generated_commands(mut self, device_generated_commands: bool) -> Self { + self.device_generated_commands = device_generated_commands.into(); + self + } + #[inline] + pub fn dynamic_generated_pipeline_layout( + mut self, + dynamic_generated_pipeline_layout: bool, + ) -> Self { + self.dynamic_generated_pipeline_layout = dynamic_generated_pipeline_layout.into(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub max_indirect_pipeline_count: u32, + pub max_indirect_shader_object_count: u32, + pub max_indirect_sequence_count: u32, + pub max_indirect_commands_token_count: u32, + pub max_indirect_commands_token_offset: u32, + pub max_indirect_commands_indirect_stride: u32, + pub supported_indirect_commands_input_modes: IndirectCommandsInputModeFlagsEXT, + pub supported_indirect_commands_shader_stages: ShaderStageFlags, + pub supported_indirect_commands_shader_stages_pipeline_binding: ShaderStageFlags, + pub supported_indirect_commands_shader_stages_shader_binding: ShaderStageFlags, + pub device_generated_commands_transform_feedback: Bool32, + pub device_generated_commands_multi_draw_indirect_count: Bool32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'_> {} +unsafe impl Sync for PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'_> {} +impl ::core::default::Default for PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null_mut(), + max_indirect_pipeline_count: u32::default(), + max_indirect_shader_object_count: u32::default(), + max_indirect_sequence_count: u32::default(), + max_indirect_commands_token_count: u32::default(), + max_indirect_commands_token_offset: u32::default(), + max_indirect_commands_indirect_stride: u32::default(), + supported_indirect_commands_input_modes: IndirectCommandsInputModeFlagsEXT::default(), + supported_indirect_commands_shader_stages: ShaderStageFlags::default(), + supported_indirect_commands_shader_stages_pipeline_binding: ShaderStageFlags::default(), + supported_indirect_commands_shader_stages_shader_binding: ShaderStageFlags::default(), + device_generated_commands_transform_feedback: Bool32::default(), + device_generated_commands_multi_draw_indirect_count: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_EXT; +} +unsafe impl ExtendsPhysicalDeviceProperties2 + for PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'_> +{ +} +impl<'a> PhysicalDeviceDeviceGeneratedCommandsPropertiesEXT<'a> { + #[inline] + pub fn max_indirect_pipeline_count(mut self, max_indirect_pipeline_count: u32) -> Self { + self.max_indirect_pipeline_count = max_indirect_pipeline_count; + self + } + #[inline] + pub fn max_indirect_shader_object_count( + mut self, + max_indirect_shader_object_count: u32, + ) -> Self { + self.max_indirect_shader_object_count = max_indirect_shader_object_count; + self + } + #[inline] + pub fn max_indirect_sequence_count(mut self, max_indirect_sequence_count: u32) -> Self { + self.max_indirect_sequence_count = max_indirect_sequence_count; + self + } + #[inline] + pub fn max_indirect_commands_token_count( + mut self, + max_indirect_commands_token_count: u32, + ) -> Self { + self.max_indirect_commands_token_count = max_indirect_commands_token_count; + self + } + #[inline] + pub fn max_indirect_commands_token_offset( + mut self, + max_indirect_commands_token_offset: u32, + ) -> Self { + self.max_indirect_commands_token_offset = max_indirect_commands_token_offset; + self + } + #[inline] + pub fn max_indirect_commands_indirect_stride( + mut self, + max_indirect_commands_indirect_stride: u32, + ) -> Self { + self.max_indirect_commands_indirect_stride = max_indirect_commands_indirect_stride; + self + } + #[inline] + pub fn supported_indirect_commands_input_modes( + mut self, + supported_indirect_commands_input_modes: IndirectCommandsInputModeFlagsEXT, + ) -> Self { + self.supported_indirect_commands_input_modes = supported_indirect_commands_input_modes; + self + } + #[inline] + pub fn supported_indirect_commands_shader_stages( + mut self, + supported_indirect_commands_shader_stages: ShaderStageFlags, + ) -> Self { + self.supported_indirect_commands_shader_stages = supported_indirect_commands_shader_stages; + self + } + #[inline] + pub fn supported_indirect_commands_shader_stages_pipeline_binding( + mut self, + supported_indirect_commands_shader_stages_pipeline_binding: ShaderStageFlags, + ) -> Self { + self.supported_indirect_commands_shader_stages_pipeline_binding = + supported_indirect_commands_shader_stages_pipeline_binding; + self + } + #[inline] + pub fn supported_indirect_commands_shader_stages_shader_binding( + mut self, + supported_indirect_commands_shader_stages_shader_binding: ShaderStageFlags, + ) -> Self { + self.supported_indirect_commands_shader_stages_shader_binding = + supported_indirect_commands_shader_stages_shader_binding; + self + } + #[inline] + pub fn device_generated_commands_transform_feedback( + mut self, + device_generated_commands_transform_feedback: bool, + ) -> Self { + self.device_generated_commands_transform_feedback = + device_generated_commands_transform_feedback.into(); + self + } + #[inline] + pub fn device_generated_commands_multi_draw_indirect_count( + mut self, + device_generated_commands_multi_draw_indirect_count: bool, + ) -> Self { + self.device_generated_commands_multi_draw_indirect_count = + device_generated_commands_multi_draw_indirect_count.into(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct GeneratedCommandsPipelineInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub pipeline: Pipeline, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for GeneratedCommandsPipelineInfoEXT<'_> {} +unsafe impl Sync for GeneratedCommandsPipelineInfoEXT<'_> {} +impl ::core::default::Default for GeneratedCommandsPipelineInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null_mut(), + pipeline: Pipeline::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for GeneratedCommandsPipelineInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::GENERATED_COMMANDS_PIPELINE_INFO_EXT; +} +unsafe impl ExtendsGeneratedCommandsInfoEXT for GeneratedCommandsPipelineInfoEXT<'_> {} +unsafe impl ExtendsGeneratedCommandsMemoryRequirementsInfoEXT + for GeneratedCommandsPipelineInfoEXT<'_> +{ +} +impl<'a> GeneratedCommandsPipelineInfoEXT<'a> { + #[inline] + pub fn pipeline(mut self, pipeline: Pipeline) -> Self { + self.pipeline = pipeline; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct GeneratedCommandsShaderInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub shader_count: u32, + pub p_shaders: *const ShaderEXT, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for GeneratedCommandsShaderInfoEXT<'_> {} +unsafe impl Sync for GeneratedCommandsShaderInfoEXT<'_> {} +impl ::core::default::Default for GeneratedCommandsShaderInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null_mut(), + shader_count: u32::default(), + p_shaders: ::core::ptr::null(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for GeneratedCommandsShaderInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::GENERATED_COMMANDS_SHADER_INFO_EXT; +} +unsafe impl ExtendsGeneratedCommandsInfoEXT for GeneratedCommandsShaderInfoEXT<'_> {} +unsafe impl ExtendsGeneratedCommandsMemoryRequirementsInfoEXT + for GeneratedCommandsShaderInfoEXT<'_> +{ +} +impl<'a> GeneratedCommandsShaderInfoEXT<'a> { + #[inline] + pub fn shaders(mut self, shaders: &'a [ShaderEXT]) -> Self { + self.shader_count = shaders.len() as _; + self.p_shaders = shaders.as_ptr(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct GeneratedCommandsMemoryRequirementsInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub indirect_execution_set: IndirectExecutionSetEXT, + pub indirect_commands_layout: IndirectCommandsLayoutEXT, + pub max_sequence_count: u32, + pub max_draw_count: u32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for GeneratedCommandsMemoryRequirementsInfoEXT<'_> {} +unsafe impl Sync for GeneratedCommandsMemoryRequirementsInfoEXT<'_> {} +impl ::core::default::Default for GeneratedCommandsMemoryRequirementsInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null_mut(), + indirect_execution_set: IndirectExecutionSetEXT::default(), + indirect_commands_layout: IndirectCommandsLayoutEXT::default(), + max_sequence_count: u32::default(), + max_draw_count: u32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for GeneratedCommandsMemoryRequirementsInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_EXT; +} +pub unsafe trait ExtendsGeneratedCommandsMemoryRequirementsInfoEXT {} +impl<'a> GeneratedCommandsMemoryRequirementsInfoEXT<'a> { + #[inline] + pub fn indirect_execution_set( + mut self, + indirect_execution_set: IndirectExecutionSetEXT, + ) -> Self { + self.indirect_execution_set = indirect_execution_set; + self + } + #[inline] + pub fn indirect_commands_layout( + mut self, + indirect_commands_layout: IndirectCommandsLayoutEXT, + ) -> Self { + self.indirect_commands_layout = indirect_commands_layout; + self + } + #[inline] + pub fn max_sequence_count(mut self, max_sequence_count: u32) -> Self { + self.max_sequence_count = max_sequence_count; + self + } + #[inline] + pub fn max_draw_count(mut self, max_draw_count: u32) -> Self { + self.max_draw_count = max_draw_count; + self + } + #[doc = r" Prepends the given extension struct between the root and the first pointer. This"] + #[doc = r" method only exists on structs that can be passed to a function directly. Only"] + #[doc = r" valid extension structs can be pushed into the chain."] + #[doc = r" If the chain looks like `A -> B -> C`, and you call `x.push_next(&mut D)`, then the"] + #[doc = r" chain will look like `A -> D -> B -> C`."] + pub fn push_next( + mut self, + next: &'a mut T, + ) -> Self { + unsafe { + let next_ptr = <*mut T>::cast(next); + let last_next = ptr_chain_iter(next).last().unwrap(); + (*last_next).p_next = self.p_next as _; + self.p_next = next_ptr; + } + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct IndirectExecutionSetPipelineInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub initial_pipeline: Pipeline, + pub max_pipeline_count: u32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for IndirectExecutionSetPipelineInfoEXT<'_> {} +unsafe impl Sync for IndirectExecutionSetPipelineInfoEXT<'_> {} +impl ::core::default::Default for IndirectExecutionSetPipelineInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + initial_pipeline: Pipeline::default(), + max_pipeline_count: u32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for IndirectExecutionSetPipelineInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::INDIRECT_EXECUTION_SET_PIPELINE_INFO_EXT; +} +impl<'a> IndirectExecutionSetPipelineInfoEXT<'a> { + #[inline] + pub fn initial_pipeline(mut self, initial_pipeline: Pipeline) -> Self { + self.initial_pipeline = initial_pipeline; + self + } + #[inline] + pub fn max_pipeline_count(mut self, max_pipeline_count: u32) -> Self { + self.max_pipeline_count = max_pipeline_count; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct IndirectExecutionSetShaderLayoutInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub set_layout_count: u32, + pub p_set_layouts: *const DescriptorSetLayout, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for IndirectExecutionSetShaderLayoutInfoEXT<'_> {} +unsafe impl Sync for IndirectExecutionSetShaderLayoutInfoEXT<'_> {} +impl ::core::default::Default for IndirectExecutionSetShaderLayoutInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + set_layout_count: u32::default(), + p_set_layouts: ::core::ptr::null(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for IndirectExecutionSetShaderLayoutInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::INDIRECT_EXECUTION_SET_SHADER_LAYOUT_INFO_EXT; +} +impl<'a> IndirectExecutionSetShaderLayoutInfoEXT<'a> { + #[inline] + pub fn set_layouts(mut self, set_layouts: &'a [DescriptorSetLayout]) -> Self { + self.set_layout_count = set_layouts.len() as _; + self.p_set_layouts = set_layouts.as_ptr(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct IndirectExecutionSetShaderInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub shader_count: u32, + pub p_initial_shaders: *const ShaderEXT, + pub p_set_layout_infos: *const IndirectExecutionSetShaderLayoutInfoEXT<'a>, + pub max_shader_count: u32, + pub push_constant_range_count: u32, + pub p_push_constant_ranges: *const PushConstantRange, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for IndirectExecutionSetShaderInfoEXT<'_> {} +unsafe impl Sync for IndirectExecutionSetShaderInfoEXT<'_> {} +impl ::core::default::Default for IndirectExecutionSetShaderInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + shader_count: u32::default(), + p_initial_shaders: ::core::ptr::null(), + p_set_layout_infos: ::core::ptr::null(), + max_shader_count: u32::default(), + push_constant_range_count: u32::default(), + p_push_constant_ranges: ::core::ptr::null(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for IndirectExecutionSetShaderInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::INDIRECT_EXECUTION_SET_SHADER_INFO_EXT; +} +impl<'a> IndirectExecutionSetShaderInfoEXT<'a> { + #[inline] + pub fn initial_shaders(mut self, initial_shaders: &'a [ShaderEXT]) -> Self { + self.shader_count = initial_shaders.len() as _; + self.p_initial_shaders = initial_shaders.as_ptr(); + self + } + #[inline] + pub fn set_layout_infos( + mut self, + set_layout_infos: &'a [IndirectExecutionSetShaderLayoutInfoEXT<'a>], + ) -> Self { + self.shader_count = set_layout_infos.len() as _; + self.p_set_layout_infos = set_layout_infos.as_ptr(); + self + } + #[inline] + pub fn max_shader_count(mut self, max_shader_count: u32) -> Self { + self.max_shader_count = max_shader_count; + self + } + #[inline] + pub fn push_constant_ranges(mut self, push_constant_ranges: &'a [PushConstantRange]) -> Self { + self.push_constant_range_count = push_constant_ranges.len() as _; + self.p_push_constant_ranges = push_constant_ranges.as_ptr(); + self + } +} +#[repr(C)] +#[derive(Copy, Clone)] +#[doc = ""] +pub union IndirectExecutionSetInfoEXT<'a> { + pub p_pipeline_info: *const IndirectExecutionSetPipelineInfoEXT<'a>, + pub p_shader_info: *const IndirectExecutionSetShaderInfoEXT<'a>, +} +impl<'a> ::core::default::Default for IndirectExecutionSetInfoEXT<'a> { + #[inline] + fn default() -> Self { + unsafe { ::core::mem::zeroed() } + } +} +#[repr(C)] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct IndirectExecutionSetCreateInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub ty: IndirectExecutionSetInfoTypeEXT, + pub info: IndirectExecutionSetInfoEXT<'a>, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for IndirectExecutionSetCreateInfoEXT<'_> {} +unsafe impl Sync for IndirectExecutionSetCreateInfoEXT<'_> {} +#[cfg(feature = "debug")] +impl fmt::Debug for IndirectExecutionSetCreateInfoEXT<'_> { + fn fmt(&self, fmt: &mut fmt::Formatter<'_>) -> fmt::Result { + fmt.debug_struct("IndirectExecutionSetCreateInfoEXT") + .field("s_type", &self.s_type) + .field("p_next", &self.p_next) + .field("ty", &self.ty) + .field("info", &"union") + .finish() + } +} +impl ::core::default::Default for IndirectExecutionSetCreateInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + ty: IndirectExecutionSetInfoTypeEXT::default(), + info: IndirectExecutionSetInfoEXT::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for IndirectExecutionSetCreateInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::INDIRECT_EXECUTION_SET_CREATE_INFO_EXT; +} +impl<'a> IndirectExecutionSetCreateInfoEXT<'a> { + #[inline] + pub fn ty(mut self, ty: IndirectExecutionSetInfoTypeEXT) -> Self { + self.ty = ty; + self + } + #[inline] + pub fn info(mut self, info: IndirectExecutionSetInfoEXT<'a>) -> Self { + self.info = info; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct GeneratedCommandsInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub shader_stages: ShaderStageFlags, + pub indirect_execution_set: IndirectExecutionSetEXT, + pub indirect_commands_layout: IndirectCommandsLayoutEXT, + pub indirect_address: DeviceAddress, + pub indirect_address_size: DeviceSize, + pub preprocess_address: DeviceAddress, + pub preprocess_size: DeviceSize, + pub max_sequence_count: u32, + pub sequence_count_address: DeviceAddress, + pub max_draw_count: u32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for GeneratedCommandsInfoEXT<'_> {} +unsafe impl Sync for GeneratedCommandsInfoEXT<'_> {} +impl ::core::default::Default for GeneratedCommandsInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + shader_stages: ShaderStageFlags::default(), + indirect_execution_set: IndirectExecutionSetEXT::default(), + indirect_commands_layout: IndirectCommandsLayoutEXT::default(), + indirect_address: DeviceAddress::default(), + indirect_address_size: DeviceSize::default(), + preprocess_address: DeviceAddress::default(), + preprocess_size: DeviceSize::default(), + max_sequence_count: u32::default(), + sequence_count_address: DeviceAddress::default(), + max_draw_count: u32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for GeneratedCommandsInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::GENERATED_COMMANDS_INFO_EXT; +} +pub unsafe trait ExtendsGeneratedCommandsInfoEXT {} +impl<'a> GeneratedCommandsInfoEXT<'a> { + #[inline] + pub fn shader_stages(mut self, shader_stages: ShaderStageFlags) -> Self { + self.shader_stages = shader_stages; + self + } + #[inline] + pub fn indirect_execution_set( + mut self, + indirect_execution_set: IndirectExecutionSetEXT, + ) -> Self { + self.indirect_execution_set = indirect_execution_set; + self + } + #[inline] + pub fn indirect_commands_layout( + mut self, + indirect_commands_layout: IndirectCommandsLayoutEXT, + ) -> Self { + self.indirect_commands_layout = indirect_commands_layout; + self + } + #[inline] + pub fn indirect_address(mut self, indirect_address: DeviceAddress) -> Self { + self.indirect_address = indirect_address; + self + } + #[inline] + pub fn indirect_address_size(mut self, indirect_address_size: DeviceSize) -> Self { + self.indirect_address_size = indirect_address_size; + self + } + #[inline] + pub fn preprocess_address(mut self, preprocess_address: DeviceAddress) -> Self { + self.preprocess_address = preprocess_address; + self + } + #[inline] + pub fn preprocess_size(mut self, preprocess_size: DeviceSize) -> Self { + self.preprocess_size = preprocess_size; + self + } + #[inline] + pub fn max_sequence_count(mut self, max_sequence_count: u32) -> Self { + self.max_sequence_count = max_sequence_count; + self + } + #[inline] + pub fn sequence_count_address(mut self, sequence_count_address: DeviceAddress) -> Self { + self.sequence_count_address = sequence_count_address; + self + } + #[inline] + pub fn max_draw_count(mut self, max_draw_count: u32) -> Self { + self.max_draw_count = max_draw_count; + self + } + #[doc = r" Prepends the given extension struct between the root and the first pointer. This"] + #[doc = r" method only exists on structs that can be passed to a function directly. Only"] + #[doc = r" valid extension structs can be pushed into the chain."] + #[doc = r" If the chain looks like `A -> B -> C`, and you call `x.push_next(&mut D)`, then the"] + #[doc = r" chain will look like `A -> D -> B -> C`."] + pub fn push_next( + mut self, + next: &'a mut T, + ) -> Self { + unsafe { + let next_ptr = <*const T>::cast(next); + let last_next = ptr_chain_iter(next).last().unwrap(); + (*last_next).p_next = self.p_next as _; + self.p_next = next_ptr; + } + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct WriteIndirectExecutionSetPipelineEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub index: u32, + pub pipeline: Pipeline, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for WriteIndirectExecutionSetPipelineEXT<'_> {} +unsafe impl Sync for WriteIndirectExecutionSetPipelineEXT<'_> {} +impl ::core::default::Default for WriteIndirectExecutionSetPipelineEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + index: u32::default(), + pipeline: Pipeline::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for WriteIndirectExecutionSetPipelineEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::WRITE_INDIRECT_EXECUTION_SET_PIPELINE_EXT; +} +impl<'a> WriteIndirectExecutionSetPipelineEXT<'a> { + #[inline] + pub fn index(mut self, index: u32) -> Self { + self.index = index; + self + } + #[inline] + pub fn pipeline(mut self, pipeline: Pipeline) -> Self { + self.pipeline = pipeline; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct WriteIndirectExecutionSetShaderEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub index: u32, + pub shader: ShaderEXT, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for WriteIndirectExecutionSetShaderEXT<'_> {} +unsafe impl Sync for WriteIndirectExecutionSetShaderEXT<'_> {} +impl ::core::default::Default for WriteIndirectExecutionSetShaderEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + index: u32::default(), + shader: ShaderEXT::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for WriteIndirectExecutionSetShaderEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::WRITE_INDIRECT_EXECUTION_SET_SHADER_EXT; +} +impl<'a> WriteIndirectExecutionSetShaderEXT<'a> { + #[inline] + pub fn index(mut self, index: u32) -> Self { + self.index = index; + self + } + #[inline] + pub fn shader(mut self, shader: ShaderEXT) -> Self { + self.shader = shader; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct IndirectCommandsLayoutCreateInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub flags: IndirectCommandsLayoutUsageFlagsEXT, + pub shader_stages: ShaderStageFlags, + pub indirect_stride: u32, + pub pipeline_layout: PipelineLayout, + pub token_count: u32, + pub p_tokens: *const IndirectCommandsLayoutTokenEXT<'a>, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for IndirectCommandsLayoutCreateInfoEXT<'_> {} +unsafe impl Sync for IndirectCommandsLayoutCreateInfoEXT<'_> {} +impl ::core::default::Default for IndirectCommandsLayoutCreateInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + flags: IndirectCommandsLayoutUsageFlagsEXT::default(), + shader_stages: ShaderStageFlags::default(), + indirect_stride: u32::default(), + pipeline_layout: PipelineLayout::default(), + token_count: u32::default(), + p_tokens: ::core::ptr::null(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for IndirectCommandsLayoutCreateInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_EXT; +} +pub unsafe trait ExtendsIndirectCommandsLayoutCreateInfoEXT {} +impl<'a> IndirectCommandsLayoutCreateInfoEXT<'a> { + #[inline] + pub fn flags(mut self, flags: IndirectCommandsLayoutUsageFlagsEXT) -> Self { + self.flags = flags; + self + } + #[inline] + pub fn shader_stages(mut self, shader_stages: ShaderStageFlags) -> Self { + self.shader_stages = shader_stages; + self + } + #[inline] + pub fn indirect_stride(mut self, indirect_stride: u32) -> Self { + self.indirect_stride = indirect_stride; + self + } + #[inline] + pub fn pipeline_layout(mut self, pipeline_layout: PipelineLayout) -> Self { + self.pipeline_layout = pipeline_layout; + self + } + #[inline] + pub fn tokens(mut self, tokens: &'a [IndirectCommandsLayoutTokenEXT<'a>]) -> Self { + self.token_count = tokens.len() as _; + self.p_tokens = tokens.as_ptr(); + self + } + #[doc = r" Prepends the given extension struct between the root and the first pointer. This"] + #[doc = r" method only exists on structs that can be passed to a function directly. Only"] + #[doc = r" valid extension structs can be pushed into the chain."] + #[doc = r" If the chain looks like `A -> B -> C`, and you call `x.push_next(&mut D)`, then the"] + #[doc = r" chain will look like `A -> D -> B -> C`."] + pub fn push_next( + mut self, + next: &'a mut T, + ) -> Self { + unsafe { + let next_ptr = <*const T>::cast(next); + let last_next = ptr_chain_iter(next).last().unwrap(); + (*last_next).p_next = self.p_next as _; + self.p_next = next_ptr; + } + self + } +} +#[repr(C)] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct IndirectCommandsLayoutTokenEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub ty: IndirectCommandsTokenTypeEXT, + pub data: IndirectCommandsTokenDataEXT, + pub offset: u32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for IndirectCommandsLayoutTokenEXT<'_> {} +unsafe impl Sync for IndirectCommandsLayoutTokenEXT<'_> {} +#[cfg(feature = "debug")] +impl fmt::Debug for IndirectCommandsLayoutTokenEXT<'_> { + fn fmt(&self, fmt: &mut fmt::Formatter<'_>) -> fmt::Result { + fmt.debug_struct("IndirectCommandsLayoutTokenEXT") + .field("s_type", &self.s_type) + .field("p_next", &self.p_next) + .field("ty", &self.ty) + .field("data", &"union") + .field("offset", &self.offset) + .finish() + } +} +impl ::core::default::Default for IndirectCommandsLayoutTokenEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + ty: IndirectCommandsTokenTypeEXT::default(), + data: IndirectCommandsTokenDataEXT::default(), + offset: u32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for IndirectCommandsLayoutTokenEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::INDIRECT_COMMANDS_LAYOUT_TOKEN_EXT; +} +impl<'a> IndirectCommandsLayoutTokenEXT<'a> { + #[inline] + pub fn ty(mut self, ty: IndirectCommandsTokenTypeEXT) -> Self { + self.ty = ty; + self + } + #[inline] + pub fn data(mut self, data: IndirectCommandsTokenDataEXT) -> Self { + self.data = data; + self + } + #[inline] + pub fn offset(mut self, offset: u32) -> Self { + self.offset = offset; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct DrawIndirectCountIndirectCommandEXT { + pub buffer_address: DeviceAddress, + pub stride: u32, + pub command_count: u32, +} +impl DrawIndirectCountIndirectCommandEXT { + #[inline] + pub fn buffer_address(mut self, buffer_address: DeviceAddress) -> Self { + self.buffer_address = buffer_address; + self + } + #[inline] + pub fn stride(mut self, stride: u32) -> Self { + self.stride = stride; + self + } + #[inline] + pub fn command_count(mut self, command_count: u32) -> Self { + self.command_count = command_count; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct IndirectCommandsVertexBufferTokenEXT { + pub vertex_binding_unit: u32, +} +impl IndirectCommandsVertexBufferTokenEXT { + #[inline] + pub fn vertex_binding_unit(mut self, vertex_binding_unit: u32) -> Self { + self.vertex_binding_unit = vertex_binding_unit; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct BindVertexBufferIndirectCommandEXT { + pub buffer_address: DeviceAddress, + pub size: u32, + pub stride: u32, +} +impl BindVertexBufferIndirectCommandEXT { + #[inline] + pub fn buffer_address(mut self, buffer_address: DeviceAddress) -> Self { + self.buffer_address = buffer_address; + self + } + #[inline] + pub fn size(mut self, size: u32) -> Self { + self.size = size; + self + } + #[inline] + pub fn stride(mut self, stride: u32) -> Self { + self.stride = stride; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct IndirectCommandsIndexBufferTokenEXT { + pub mode: IndirectCommandsInputModeFlagsEXT, +} +impl IndirectCommandsIndexBufferTokenEXT { + #[inline] + pub fn mode(mut self, mode: IndirectCommandsInputModeFlagsEXT) -> Self { + self.mode = mode; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct BindIndexBufferIndirectCommandEXT { + pub buffer_address: DeviceAddress, + pub size: u32, + pub index_type: IndexType, +} +impl BindIndexBufferIndirectCommandEXT { + #[inline] + pub fn buffer_address(mut self, buffer_address: DeviceAddress) -> Self { + self.buffer_address = buffer_address; + self + } + #[inline] + pub fn size(mut self, size: u32) -> Self { + self.size = size; + self + } + #[inline] + pub fn index_type(mut self, index_type: IndexType) -> Self { + self.index_type = index_type; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct IndirectCommandsPushConstantTokenEXT { + pub update_range: PushConstantRange, +} +impl IndirectCommandsPushConstantTokenEXT { + #[inline] + pub fn update_range(mut self, update_range: PushConstantRange) -> Self { + self.update_range = update_range; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct IndirectCommandsExecutionSetTokenEXT { + pub ty: IndirectExecutionSetInfoTypeEXT, + pub shader_stages: ShaderStageFlags, +} +impl IndirectCommandsExecutionSetTokenEXT { + #[inline] + pub fn ty(mut self, ty: IndirectExecutionSetInfoTypeEXT) -> Self { + self.ty = ty; + self + } + #[inline] + pub fn shader_stages(mut self, shader_stages: ShaderStageFlags) -> Self { + self.shader_stages = shader_stages; + self + } +} +#[repr(C)] +#[derive(Copy, Clone)] +#[doc = ""] +pub union IndirectCommandsTokenDataEXT { + pub p_push_constant: *const IndirectCommandsPushConstantTokenEXT, + pub p_vertex_buffer: *const IndirectCommandsVertexBufferTokenEXT, + pub p_index_buffer: *const IndirectCommandsIndexBufferTokenEXT, + pub p_execution_set: *const IndirectCommandsExecutionSetTokenEXT, +} +impl ::core::default::Default for IndirectCommandsTokenDataEXT { + #[inline] + fn default() -> Self { + unsafe { ::core::mem::zeroed() } + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] #[doc = ""] #[must_use] pub struct PipelineViewportDepthClipControlCreateInfoEXT<'a> { @@ -38473,6 +39552,89 @@ impl<'a> PipelineViewportDepthClipControlCreateInfoEXT<'a> { #[repr(C)] #[cfg_attr(feature = "debug", derive(Debug))] #[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct PhysicalDeviceDepthClampControlFeaturesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub depth_clamp_control: Bool32, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for PhysicalDeviceDepthClampControlFeaturesEXT<'_> {} +unsafe impl Sync for PhysicalDeviceDepthClampControlFeaturesEXT<'_> {} +impl ::core::default::Default for PhysicalDeviceDepthClampControlFeaturesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null_mut(), + depth_clamp_control: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceDepthClampControlFeaturesEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_DEPTH_CLAMP_CONTROL_FEATURES_EXT; +} +unsafe impl ExtendsPhysicalDeviceFeatures2 for PhysicalDeviceDepthClampControlFeaturesEXT<'_> {} +unsafe impl ExtendsDeviceCreateInfo for PhysicalDeviceDepthClampControlFeaturesEXT<'_> {} +impl<'a> PhysicalDeviceDepthClampControlFeaturesEXT<'a> { + #[inline] + pub fn depth_clamp_control(mut self, depth_clamp_control: bool) -> Self { + self.depth_clamp_control = depth_clamp_control.into(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +#[must_use] +pub struct PipelineViewportDepthClampControlCreateInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub depth_clamp_mode: DepthClampModeEXT, + pub p_depth_clamp_range: *const DepthClampRangeEXT, + pub _marker: PhantomData<&'a ()>, +} +unsafe impl Send for PipelineViewportDepthClampControlCreateInfoEXT<'_> {} +unsafe impl Sync for PipelineViewportDepthClampControlCreateInfoEXT<'_> {} +impl ::core::default::Default for PipelineViewportDepthClampControlCreateInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::core::ptr::null(), + depth_clamp_mode: DepthClampModeEXT::default(), + p_depth_clamp_range: ::core::ptr::null(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PipelineViewportDepthClampControlCreateInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PIPELINE_VIEWPORT_DEPTH_CLAMP_CONTROL_CREATE_INFO_EXT; +} +unsafe impl ExtendsPipelineViewportStateCreateInfo + for PipelineViewportDepthClampControlCreateInfoEXT<'_> +{ +} +impl<'a> PipelineViewportDepthClampControlCreateInfoEXT<'a> { + #[inline] + pub fn depth_clamp_mode(mut self, depth_clamp_mode: DepthClampModeEXT) -> Self { + self.depth_clamp_mode = depth_clamp_mode; + self + } + #[inline] + pub fn depth_clamp_range(mut self, depth_clamp_range: &'a DepthClampRangeEXT) -> Self { + self.p_depth_clamp_range = depth_clamp_range; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] #[doc = ""] #[must_use] pub struct PhysicalDeviceVertexInputDynamicStateFeaturesEXT<'a> { @@ -58725,3 +59887,24 @@ impl<'a> PhysicalDeviceShaderReplicatedCompositesFeaturesEXT<'a> { self } } +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone, Default)] +#[doc = ""] +#[must_use] +pub struct DepthClampRangeEXT { + pub min_depth_clamp: f32, + pub max_depth_clamp: f32, +} +impl DepthClampRangeEXT { + #[inline] + pub fn min_depth_clamp(mut self, min_depth_clamp: f32) -> Self { + self.min_depth_clamp = min_depth_clamp; + self + } + #[inline] + pub fn max_depth_clamp(mut self, max_depth_clamp: f32) -> Self { + self.max_depth_clamp = max_depth_clamp; + self + } +} diff --git a/ash/src/vk/enums.rs b/ash/src/vk/enums.rs index e81716bc0..ee9da963e 100644 --- a/ash/src/vk/enums.rs +++ b/ash/src/vk/enums.rs @@ -2792,6 +2792,50 @@ impl DeviceFaultVendorBinaryHeaderVersionEXT { } #[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Default)] #[repr(transparent)] +#[doc = ""] +pub struct IndirectExecutionSetInfoTypeEXT(pub(crate) i32); +impl IndirectExecutionSetInfoTypeEXT { + #[inline] + pub const fn from_raw(x: i32) -> Self { + Self(x) + } + #[inline] + pub const fn as_raw(self) -> i32 { + self.0 + } +} +impl IndirectExecutionSetInfoTypeEXT { + pub const PIPELINES: Self = Self(0); + pub const SHADER_OBJECTS: Self = Self(1); +} +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Default)] +#[repr(transparent)] +#[doc = ""] +pub struct IndirectCommandsTokenTypeEXT(pub(crate) i32); +impl IndirectCommandsTokenTypeEXT { + #[inline] + pub const fn from_raw(x: i32) -> Self { + Self(x) + } + #[inline] + pub const fn as_raw(self) -> i32 { + self.0 + } +} +impl IndirectCommandsTokenTypeEXT { + pub const EXECUTION_SET: Self = Self(0); + pub const PUSH_CONSTANT: Self = Self(1); + pub const SEQUENCE_INDEX: Self = Self(2); + pub const INDEX_BUFFER: Self = Self(3); + pub const VERTEX_BUFFER: Self = Self(4); + pub const DRAW_INDEXED: Self = Self(5); + pub const DRAW: Self = Self(6); + pub const DRAW_INDEXED_COUNT: Self = Self(7); + pub const DRAW_COUNT: Self = Self(8); + pub const DISPATCH: Self = Self(9); +} +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Default)] +#[repr(transparent)] #[doc = ""] pub struct DisplacementMicromapFormatNV(pub(crate) i32); impl DisplacementMicromapFormatNV { @@ -2997,6 +3041,24 @@ impl OutOfBandQueueTypeNV { pub const RENDER: Self = Self(0); pub const PRESENT: Self = Self(1); } +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Default)] +#[repr(transparent)] +#[doc = ""] +pub struct DepthClampModeEXT(pub(crate) i32); +impl DepthClampModeEXT { + #[inline] + pub const fn from_raw(x: i32) -> Self { + Self(x) + } + #[inline] + pub const fn as_raw(self) -> i32 { + self.0 + } +} +impl DepthClampModeEXT { + pub const VIEWPORT_RANGE: Self = Self(0); + pub const USER_DEFINED_RANGE: Self = Self(1); +} impl fmt::Debug for ObjectType { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { let name = match *self { @@ -3049,6 +3111,8 @@ impl fmt::Debug for ObjectType { Self::OPTICAL_FLOW_SESSION_NV => Some("OPTICAL_FLOW_SESSION_NV"), Self::SHADER_EXT => Some("SHADER_EXT"), Self::PIPELINE_BINARY_KHR => Some("PIPELINE_BINARY_KHR"), + Self::INDIRECT_COMMANDS_LAYOUT_EXT => Some("INDIRECT_COMMANDS_LAYOUT_EXT"), + Self::INDIRECT_EXECUTION_SET_EXT => Some("INDIRECT_EXECUTION_SET_EXT"), Self::SAMPLER_YCBCR_CONVERSION => Some("SAMPLER_YCBCR_CONVERSION"), Self::DESCRIPTOR_UPDATE_TEMPLATE => Some("DESCRIPTOR_UPDATE_TEMPLATE"), Self::PRIVATE_DATA_SLOT => Some("PRIVATE_DATA_SLOT"), diff --git a/ash/src/vk/extensions.rs b/ash/src/vk/extensions.rs index 5bca91fd7..8d84a766e 100644 --- a/ash/src/vk/extensions.rs +++ b/ash/src/vk/extensions.rs @@ -1745,6 +1745,11 @@ impl StructureType { Self::PHYSICAL_DEVICE_COMPUTE_SHADER_DERIVATIVES_FEATURES_KHR; } #[doc = "Generated from 'VK_NV_mesh_shader'"] +impl IndirectCommandsTokenTypeEXT { + pub const DRAW_MESH_TASKS_NV: Self = Self(1_000_202_002); + pub const DRAW_MESH_TASKS_COUNT_NV: Self = Self(1_000_202_003); +} +#[doc = "Generated from 'VK_NV_mesh_shader'"] impl PipelineStageFlags { pub const TASK_SHADER_NV: Self = Self::TASK_SHADER_EXT; pub const MESH_SHADER_NV: Self = Self::MESH_SHADER_EXT; @@ -2577,6 +2582,8 @@ impl AccessFlags2 { pub const CONDITIONAL_RENDERING_READ_EXT: Self = Self(0b1_0000_0000_0000_0000_0000); pub const COMMAND_PREPROCESS_READ_NV: Self = Self(0b10_0000_0000_0000_0000); pub const COMMAND_PREPROCESS_WRITE_NV: Self = Self(0b100_0000_0000_0000_0000); + pub const COMMAND_PREPROCESS_READ_EXT: Self = Self::COMMAND_PREPROCESS_READ_NV; + pub const COMMAND_PREPROCESS_WRITE_EXT: Self = Self::COMMAND_PREPROCESS_WRITE_NV; pub const FRAGMENT_SHADING_RATE_ATTACHMENT_READ_KHR: Self = Self(0b1000_0000_0000_0000_0000_0000); pub const SHADING_RATE_IMAGE_READ_NV: Self = Self::FRAGMENT_SHADING_RATE_ATTACHMENT_READ_KHR; @@ -2606,6 +2613,7 @@ impl PipelineStageFlags2 { #[doc = "A pipeline stage for conditional rendering predicate fetch"] pub const CONDITIONAL_RENDERING_EXT: Self = Self(0b100_0000_0000_0000_0000); pub const COMMAND_PREPROCESS_NV: Self = Self(0b10_0000_0000_0000_0000); + pub const COMMAND_PREPROCESS_EXT: Self = Self::COMMAND_PREPROCESS_NV; pub const FRAGMENT_SHADING_RATE_ATTACHMENT_KHR: Self = Self(0b100_0000_0000_0000_0000_0000); pub const SHADING_RATE_IMAGE_NV: Self = Self::FRAGMENT_SHADING_RATE_ATTACHMENT_KHR; pub const ACCELERATION_STRUCTURE_BUILD_KHR: Self = Self(0b10_0000_0000_0000_0000_0000_0000); @@ -2752,6 +2760,11 @@ impl StructureType { pub const ACCELERATION_STRUCTURE_MOTION_INFO_NV: Self = Self(1_000_327_002); } #[doc = "Generated from 'VK_EXT_mesh_shader'"] +impl IndirectCommandsTokenTypeEXT { + pub const DRAW_MESH_TASKS: Self = Self(1_000_328_000); + pub const DRAW_MESH_TASKS_COUNT: Self = Self(1_000_328_001); +} +#[doc = "Generated from 'VK_EXT_mesh_shader'"] impl IndirectCommandsTokenTypeNV { pub const DRAW_MESH_TASKS: Self = Self(1_000_328_000); } @@ -3125,6 +3138,10 @@ impl AccessFlags2 { Self(0b1_0000_0000_0000_0000_0000_0000_0000_0000_0000_0000); } #[doc = "Generated from 'VK_KHR_ray_tracing_maintenance1'"] +impl IndirectCommandsTokenTypeEXT { + pub const TRACE_RAYS2: Self = Self(1_000_386_004); +} +#[doc = "Generated from 'VK_KHR_ray_tracing_maintenance1'"] impl PipelineStageFlags2 { pub const ACCELERATION_STRUCTURE_COPY_KHR: Self = Self(0b1_0000_0000_0000_0000_0000_0000_0000); } @@ -4035,12 +4052,65 @@ impl StructureType { impl StructureType { pub const PHYSICAL_DEVICE_RAY_TRACING_VALIDATION_FEATURES_NV: Self = Self(1_000_568_000); } +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl AccessFlags { + pub const COMMAND_PREPROCESS_READ_EXT: Self = Self::COMMAND_PREPROCESS_READ_NV; + pub const COMMAND_PREPROCESS_WRITE_EXT: Self = Self::COMMAND_PREPROCESS_WRITE_NV; +} +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl BufferUsageFlags2KHR { + pub const PREPROCESS_BUFFER_EXT: Self = Self(0b1000_0000_0000_0000_0000_0000_0000_0000); +} +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl ObjectType { + pub const INDIRECT_COMMANDS_LAYOUT_EXT: Self = Self(1_000_572_000); + pub const INDIRECT_EXECUTION_SET_EXT: Self = Self(1_000_572_001); +} +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl PipelineCreateFlags2KHR { + pub const INDIRECT_BINDABLE_EXT: Self = + Self(0b100_0000_0000_0000_0000_0000_0000_0000_0000_0000); +} +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl PipelineStageFlags { + pub const COMMAND_PREPROCESS_EXT: Self = Self::COMMAND_PREPROCESS_NV; +} +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl ShaderCreateFlagsEXT { + pub const INDIRECT_BINDABLE: Self = Self(0b1000_0000); +} +#[doc = "Generated from 'VK_EXT_device_generated_commands'"] +impl StructureType { + pub const PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_EXT: Self = Self(1_000_572_000); + pub const PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_EXT: Self = Self(1_000_572_001); + pub const GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_EXT: Self = Self(1_000_572_002); + pub const INDIRECT_EXECUTION_SET_CREATE_INFO_EXT: Self = Self(1_000_572_003); + pub const GENERATED_COMMANDS_INFO_EXT: Self = Self(1_000_572_004); + pub const INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_EXT: Self = Self(1_000_572_006); + pub const INDIRECT_COMMANDS_LAYOUT_TOKEN_EXT: Self = Self(1_000_572_007); + pub const WRITE_INDIRECT_EXECUTION_SET_PIPELINE_EXT: Self = Self(1_000_572_008); + pub const WRITE_INDIRECT_EXECUTION_SET_SHADER_EXT: Self = Self(1_000_572_009); + pub const INDIRECT_EXECUTION_SET_PIPELINE_INFO_EXT: Self = Self(1_000_572_010); + pub const INDIRECT_EXECUTION_SET_SHADER_INFO_EXT: Self = Self(1_000_572_011); + pub const INDIRECT_EXECUTION_SET_SHADER_LAYOUT_INFO_EXT: Self = Self(1_000_572_012); + pub const GENERATED_COMMANDS_PIPELINE_INFO_EXT: Self = Self(1_000_572_013); + pub const GENERATED_COMMANDS_SHADER_INFO_EXT: Self = Self(1_000_572_014); +} #[doc = "Generated from 'VK_MESA_image_alignment_control'"] impl StructureType { pub const PHYSICAL_DEVICE_IMAGE_ALIGNMENT_CONTROL_FEATURES_MESA: Self = Self(1_000_575_000); pub const PHYSICAL_DEVICE_IMAGE_ALIGNMENT_CONTROL_PROPERTIES_MESA: Self = Self(1_000_575_001); pub const IMAGE_ALIGNMENT_CONTROL_CREATE_INFO_MESA: Self = Self(1_000_575_002); } +#[doc = "Generated from 'VK_EXT_depth_clamp_control'"] +impl DynamicState { + pub const DEPTH_CLAMP_RANGE_EXT: Self = Self(1_000_582_000); +} +#[doc = "Generated from 'VK_EXT_depth_clamp_control'"] +impl StructureType { + pub const PHYSICAL_DEVICE_DEPTH_CLAMP_CONTROL_FEATURES_EXT: Self = Self(1_000_582_000); + pub const PIPELINE_VIEWPORT_DEPTH_CLAMP_CONTROL_CREATE_INFO_EXT: Self = Self(1_000_582_001); +} pub const KHR_SURFACE_NAME: &CStr = unsafe { CStr::from_bytes_with_nul_unchecked(b"VK_KHR_surface\0") }; pub const KHR_SURFACE_SPEC_VERSION: u32 = 25u32; @@ -7783,6 +7853,12 @@ pub type PFN_vkCmdBindShadersEXT = unsafe extern "system" fn( p_stages: *const ShaderStageFlags, p_shaders: *const ShaderEXT, ); +#[allow(non_camel_case_types)] +pub type PFN_vkCmdSetDepthClampRangeEXT = unsafe extern "system" fn( + command_buffer: CommandBuffer, + depth_clamp_mode: DepthClampModeEXT, + p_depth_clamp_range: *const DepthClampRangeEXT, +); pub const KHR_PIPELINE_BINARY_NAME: &CStr = unsafe { CStr::from_bytes_with_nul_unchecked(b"VK_KHR_pipeline_binary\0") }; pub const KHR_PIPELINE_BINARY_SPEC_VERSION: u32 = 1u32; @@ -8027,6 +8103,70 @@ pub const EXT_SHADER_REPLICATED_COMPOSITES_SPEC_VERSION: u32 = 1u32; pub const NV_RAY_TRACING_VALIDATION_NAME: &CStr = unsafe { CStr::from_bytes_with_nul_unchecked(b"VK_NV_ray_tracing_validation\0") }; pub const NV_RAY_TRACING_VALIDATION_SPEC_VERSION: u32 = 1u32; +pub const EXT_DEVICE_GENERATED_COMMANDS_NAME: &CStr = + unsafe { CStr::from_bytes_with_nul_unchecked(b"VK_EXT_device_generated_commands\0") }; +pub const EXT_DEVICE_GENERATED_COMMANDS_SPEC_VERSION: u32 = 1u32; +#[allow(non_camel_case_types)] +pub type PFN_vkGetGeneratedCommandsMemoryRequirementsEXT = unsafe extern "system" fn( + device: crate::vk::Device, + p_info: *const GeneratedCommandsMemoryRequirementsInfoEXT<'_>, + p_memory_requirements: *mut MemoryRequirements2<'_>, +); +#[allow(non_camel_case_types)] +pub type PFN_vkCmdPreprocessGeneratedCommandsEXT = unsafe extern "system" fn( + command_buffer: CommandBuffer, + p_generated_commands_info: *const GeneratedCommandsInfoEXT<'_>, + state_command_buffer: CommandBuffer, +); +#[allow(non_camel_case_types)] +pub type PFN_vkCmdExecuteGeneratedCommandsEXT = unsafe extern "system" fn( + command_buffer: CommandBuffer, + is_preprocessed: Bool32, + p_generated_commands_info: *const GeneratedCommandsInfoEXT<'_>, +); +#[allow(non_camel_case_types)] +pub type PFN_vkCreateIndirectCommandsLayoutEXT = unsafe extern "system" fn( + device: crate::vk::Device, + p_create_info: *const IndirectCommandsLayoutCreateInfoEXT<'_>, + p_allocator: *const AllocationCallbacks<'_>, + p_indirect_commands_layout: *mut IndirectCommandsLayoutEXT, +) -> Result; +#[allow(non_camel_case_types)] +pub type PFN_vkDestroyIndirectCommandsLayoutEXT = unsafe extern "system" fn( + device: crate::vk::Device, + indirect_commands_layout: IndirectCommandsLayoutEXT, + p_allocator: *const AllocationCallbacks<'_>, +); +#[allow(non_camel_case_types)] +pub type PFN_vkCreateIndirectExecutionSetEXT = unsafe extern "system" fn( + device: crate::vk::Device, + p_create_info: *const IndirectExecutionSetCreateInfoEXT<'_>, + p_allocator: *const AllocationCallbacks<'_>, + p_indirect_execution_set: *mut IndirectExecutionSetEXT, +) -> Result; +#[allow(non_camel_case_types)] +pub type PFN_vkDestroyIndirectExecutionSetEXT = unsafe extern "system" fn( + device: crate::vk::Device, + indirect_execution_set: IndirectExecutionSetEXT, + p_allocator: *const AllocationCallbacks<'_>, +); +#[allow(non_camel_case_types)] +pub type PFN_vkUpdateIndirectExecutionSetPipelineEXT = unsafe extern "system" fn( + device: crate::vk::Device, + indirect_execution_set: IndirectExecutionSetEXT, + execution_set_write_count: u32, + p_execution_set_writes: *const WriteIndirectExecutionSetPipelineEXT<'_>, +); +#[allow(non_camel_case_types)] +pub type PFN_vkUpdateIndirectExecutionSetShaderEXT = unsafe extern "system" fn( + device: crate::vk::Device, + indirect_execution_set: IndirectExecutionSetEXT, + execution_set_write_count: u32, + p_execution_set_writes: *const WriteIndirectExecutionSetShaderEXT<'_>, +); pub const MESA_IMAGE_ALIGNMENT_CONTROL_NAME: &CStr = unsafe { CStr::from_bytes_with_nul_unchecked(b"VK_MESA_image_alignment_control\0") }; pub const MESA_IMAGE_ALIGNMENT_CONTROL_SPEC_VERSION: u32 = 1u32; +pub const EXT_DEPTH_CLAMP_CONTROL_NAME: &CStr = + unsafe { CStr::from_bytes_with_nul_unchecked(b"VK_EXT_depth_clamp_control\0") }; +pub const EXT_DEPTH_CLAMP_CONTROL_SPEC_VERSION: u32 = 1u32; diff --git a/generator/Vulkan-Headers b/generator/Vulkan-Headers index fbda05468..29f979ee5 160000 --- a/generator/Vulkan-Headers +++ b/generator/Vulkan-Headers @@ -1 +1 @@ -Subproject commit fbda05468ec5956bc4f163b50c18b8df9312cdee +Subproject commit 29f979ee5aa58b7b005f805ea8df7a855c39ff37