From 7ac00278521ccae2403cbf0cf8cc46e003f311d8 Mon Sep 17 00:00:00 2001 From: Marijn Suijten Date: Mon, 3 Apr 2023 10:18:26 +0200 Subject: [PATCH] Update Vulkan-Headers to 1.3.246 (#723) * Update Vulkan-Headers to 1.3.245 * Upgrade `bindgen` to `0.64` * Update Vulkan-Headers to 1.3.246 --- Changelog.md | 2 +- ash/Cargo.toml | 2 +- ash/src/vk/aliases.rs | 2 + ash/src/vk/bitflags.rs | 14 + ash/src/vk/const_debugs.rs | 86 +++ ash/src/vk/definitions.rs | 578 ++++++++++++++++- ash/src/vk/enums.rs | 41 ++ ash/src/vk/extensions.rs | 1247 ++++++++++++++++++++++++++++++++++++ ash/src/vk/native.rs | 2 +- generator/Cargo.toml | 2 +- generator/Vulkan-Headers | 2 +- 11 files changed, 1972 insertions(+), 6 deletions(-) diff --git a/Changelog.md b/Changelog.md index 5d08a82..902bd8c 100644 --- a/Changelog.md +++ b/Changelog.md @@ -8,7 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added -- Update Vulkan-Headers to 1.3.244 (#697) +- Update Vulkan-Headers to 1.3.246 (#697, #723) - Added `VK_KHR_performance_query` device extension (#726) ### Changed diff --git a/ash/Cargo.toml b/ash/Cargo.toml index cf685cd..7fa31ab 100644 --- a/ash/Cargo.toml +++ b/ash/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ash" -version = "0.37.0+1.3.244" +version = "0.37.0+1.3.246" authors = [ "Maik Klein ", "Benjamin Saunders ", diff --git a/ash/src/vk/aliases.rs b/ash/src/vk/aliases.rs index fda56e0..f3a6a17 100644 --- a/ash/src/vk/aliases.rs +++ b/ash/src/vk/aliases.rs @@ -218,6 +218,8 @@ pub type PhysicalDeviceSubgroupSizeControlPropertiesEXT<'a> = PhysicalDeviceSubgroupSizeControlProperties<'a>; pub type PipelineShaderStageRequiredSubgroupSizeCreateInfoEXT<'a> = PipelineShaderStageRequiredSubgroupSizeCreateInfo<'a>; +pub type ShaderRequiredSubgroupSizeCreateInfoEXT<'a> = + PipelineShaderStageRequiredSubgroupSizeCreateInfo<'a>; pub type MemoryOpaqueCaptureAddressAllocateInfoKHR<'a> = MemoryOpaqueCaptureAddressAllocateInfo<'a>; pub type DeviceMemoryOpaqueCaptureAddressInfoKHR<'a> = DeviceMemoryOpaqueCaptureAddressInfo<'a>; pub type PhysicalDevicePipelineCreationCacheControlFeaturesEXT<'a> = diff --git a/ash/src/vk/bitflags.rs b/ash/src/vk/bitflags.rs index 2f48e7d..1189e1e 100644 --- a/ash/src/vk/bitflags.rs +++ b/ash/src/vk/bitflags.rs @@ -1613,3 +1613,17 @@ vk_bitflags_wrapped!(MicromapCreateFlagsEXT, Flags); impl MicromapCreateFlagsEXT { pub const DEVICE_ADDRESS_CAPTURE_REPLAY: Self = Self(0b1); } +#[repr(transparent)] +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash)] +#[doc = ""] +pub struct ShaderCreateFlagsEXT(pub(crate) Flags); +vk_bitflags_wrapped!(ShaderCreateFlagsEXT, Flags); +impl ShaderCreateFlagsEXT { + pub const LINK_STAGE: Self = Self(0b1); + pub const ALLOW_VARYING_SUBGROUP_SIZE: Self = Self(0b10); + pub const REQUIRE_FULL_SUBGROUPS: Self = Self(0b100); + pub const NO_TASK_SHADER: Self = Self(0b1000); + pub const DISPATCH_BASE: Self = Self(0b1_0000); + pub const FRAGMENT_SHADING_RATE_ATTACHMENT: Self = Self(0b10_0000); + pub const FRAGMENT_DENSITY_MAP_ATTACHMENT: Self = Self(0b100_0000); +} diff --git a/ash/src/vk/const_debugs.rs b/ash/src/vk/const_debugs.rs index 17741e4..81290c7 100644 --- a/ash/src/vk/const_debugs.rs +++ b/ash/src/vk/const_debugs.rs @@ -651,6 +651,10 @@ impl fmt::Debug for BuildAccelerationStructureFlagsKHR { BuildAccelerationStructureFlagsKHR::ALLOW_OPACITY_MICROMAP_DATA_UPDATE_EXT.0, "ALLOW_OPACITY_MICROMAP_DATA_UPDATE_EXT", ), + ( + BuildAccelerationStructureFlagsKHR::ALLOW_DISPLACEMENT_MICROMAP_UPDATE_NV.0, + "ALLOW_DISPLACEMENT_MICROMAP_UPDATE_NV", + ), ]; debug_flags(f, KNOWN, self.0) } @@ -1419,6 +1423,21 @@ impl fmt::Debug for DiscardRectangleModeEXT { } } } +impl fmt::Debug for DisplacementMicromapFormatNV { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + let name = match *self { + Self::TYPE_64_TRIANGLES_64_BYTES => Some("TYPE_64_TRIANGLES_64_BYTES"), + Self::TYPE_256_TRIANGLES_128_BYTES => Some("TYPE_256_TRIANGLES_128_BYTES"), + Self::TYPE_1024_TRIANGLES_128_BYTES => Some("TYPE_1024_TRIANGLES_128_BYTES"), + _ => None, + }; + if let Some(x) = name { + f.write_str(x) + } else { + self.0.fmt(f) + } + } +} impl fmt::Debug for DisplayEventTypeEXT { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { let name = match *self { @@ -2926,6 +2945,7 @@ impl fmt::Debug for MicromapTypeEXT { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { let name = match *self { Self::OPACITY_MICROMAP => Some("OPACITY_MICROMAP"), + Self::DISPLACEMENT_MICROMAP_NV => Some("DISPLACEMENT_MICROMAP_NV"), _ => None, }; if let Some(x) = name { @@ -3383,6 +3403,10 @@ impl fmt::Debug for PipelineCreateFlags { PipelineCreateFlags::RAY_TRACING_OPACITY_MICROMAP_EXT.0, "RAY_TRACING_OPACITY_MICROMAP_EXT", ), + ( + PipelineCreateFlags::RAY_TRACING_DISPLACEMENT_MICROMAP_NV.0, + "RAY_TRACING_DISPLACEMENT_MICROMAP_NV", + ), ( PipelineCreateFlags::NO_PROTECTED_ACCESS_EXT.0, "NO_PROTECTED_ACCESS_EXT", @@ -4295,12 +4319,52 @@ impl fmt::Debug for SemaphoreWaitFlags { debug_flags(f, KNOWN, self.0) } } +impl fmt::Debug for ShaderCodeTypeEXT { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + let name = match *self { + Self::BINARY => Some("BINARY"), + Self::SPIRV => Some("SPIRV"), + _ => None, + }; + if let Some(x) = name { + f.write_str(x) + } else { + self.0.fmt(f) + } + } +} impl fmt::Debug for ShaderCorePropertiesFlagsAMD { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { const KNOWN: &[(Flags, &str)] = &[]; debug_flags(f, KNOWN, self.0) } } +impl fmt::Debug for ShaderCreateFlagsEXT { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + const KNOWN: &[(Flags, &str)] = &[ + (ShaderCreateFlagsEXT::LINK_STAGE.0, "LINK_STAGE"), + ( + ShaderCreateFlagsEXT::ALLOW_VARYING_SUBGROUP_SIZE.0, + "ALLOW_VARYING_SUBGROUP_SIZE", + ), + ( + ShaderCreateFlagsEXT::REQUIRE_FULL_SUBGROUPS.0, + "REQUIRE_FULL_SUBGROUPS", + ), + (ShaderCreateFlagsEXT::NO_TASK_SHADER.0, "NO_TASK_SHADER"), + (ShaderCreateFlagsEXT::DISPATCH_BASE.0, "DISPATCH_BASE"), + ( + ShaderCreateFlagsEXT::FRAGMENT_SHADING_RATE_ATTACHMENT.0, + "FRAGMENT_SHADING_RATE_ATTACHMENT", + ), + ( + ShaderCreateFlagsEXT::FRAGMENT_DENSITY_MAP_ATTACHMENT.0, + "FRAGMENT_DENSITY_MAP_ATTACHMENT", + ), + ]; + debug_flags(f, KNOWN, self.0) + } +} impl fmt::Debug for ShaderFloatControlsIndependence { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { let name = match *self { @@ -5645,6 +5709,12 @@ impl fmt::Debug for StructureType { Self::PHYSICAL_DEVICE_IMAGE_2D_VIEW_OF_3D_FEATURES_EXT => { Some("PHYSICAL_DEVICE_IMAGE_2D_VIEW_OF_3D_FEATURES_EXT") } + Self::PHYSICAL_DEVICE_SHADER_TILE_IMAGE_FEATURES_EXT => { + Some("PHYSICAL_DEVICE_SHADER_TILE_IMAGE_FEATURES_EXT") + } + Self::PHYSICAL_DEVICE_SHADER_TILE_IMAGE_PROPERTIES_EXT => { + Some("PHYSICAL_DEVICE_SHADER_TILE_IMAGE_PROPERTIES_EXT") + } Self::MICROMAP_BUILD_INFO_EXT => Some("MICROMAP_BUILD_INFO_EXT"), Self::MICROMAP_VERSION_INFO_EXT => Some("MICROMAP_VERSION_INFO_EXT"), Self::COPY_MICROMAP_INFO_EXT => Some("COPY_MICROMAP_INFO_EXT"), @@ -5661,6 +5731,15 @@ impl fmt::Debug for StructureType { Self::ACCELERATION_STRUCTURE_TRIANGLES_OPACITY_MICROMAP_EXT => { Some("ACCELERATION_STRUCTURE_TRIANGLES_OPACITY_MICROMAP_EXT") } + Self::PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_FEATURES_NV => { + Some("PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_FEATURES_NV") + } + Self::PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_PROPERTIES_NV => { + Some("PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_PROPERTIES_NV") + } + Self::ACCELERATION_STRUCTURE_TRIANGLES_DISPLACEMENT_MICROMAP_NV => { + Some("ACCELERATION_STRUCTURE_TRIANGLES_DISPLACEMENT_MICROMAP_NV") + } Self::PHYSICAL_DEVICE_CLUSTER_CULLING_SHADER_FEATURES_HUAWEI => { Some("PHYSICAL_DEVICE_CLUSTER_CULLING_SHADER_FEATURES_HUAWEI") } @@ -5788,6 +5867,13 @@ impl fmt::Debug for StructureType { Self::PHYSICAL_DEVICE_PIPELINE_PROTECTED_ACCESS_FEATURES_EXT => { Some("PHYSICAL_DEVICE_PIPELINE_PROTECTED_ACCESS_FEATURES_EXT") } + Self::PHYSICAL_DEVICE_SHADER_OBJECT_FEATURES_EXT => { + Some("PHYSICAL_DEVICE_SHADER_OBJECT_FEATURES_EXT") + } + Self::PHYSICAL_DEVICE_SHADER_OBJECT_PROPERTIES_EXT => { + Some("PHYSICAL_DEVICE_SHADER_OBJECT_PROPERTIES_EXT") + } + Self::SHADER_CREATE_INFO_EXT => Some("SHADER_CREATE_INFO_EXT"), Self::PHYSICAL_DEVICE_TILE_PROPERTIES_FEATURES_QCOM => { Some("PHYSICAL_DEVICE_TILE_PROPERTIES_FEATURES_QCOM") } diff --git a/ash/src/vk/definitions.rs b/ash/src/vk/definitions.rs index 6f07920..69ea142 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 = 244; +pub const HEADER_VERSION: u32 = 246; #[doc = ""] pub const HEADER_VERSION_COMPLETE: u32 = make_api_version(0, 1, 3, HEADER_VERSION); #[doc = ""] @@ -433,6 +433,12 @@ handle_nondispatchable ! (CuModuleNVX , CU_MODULE_NVX , doc = "" +); handle_nondispatchable!( DisplayKHR, DISPLAY_KHR, @@ -28215,6 +28221,7 @@ unsafe impl ExtendsPipelineShaderStageCreateInfo for PipelineShaderStageRequiredSubgroupSizeCreateInfo<'_> { } +unsafe impl ExtendsShaderCreateInfoEXT for PipelineShaderStageRequiredSubgroupSizeCreateInfo<'_> {} impl<'a> PipelineShaderStageRequiredSubgroupSizeCreateInfo<'a> { #[inline] pub fn required_subgroup_size(mut self, required_subgroup_size: u32) -> Self { @@ -44318,6 +44325,275 @@ impl<'a> AccelerationStructureTrianglesOpacityMicromapEXT<'a> { #[repr(C)] #[cfg_attr(feature = "debug", derive(Debug))] #[derive(Copy, Clone)] +#[doc = ""] +pub struct PhysicalDeviceDisplacementMicromapFeaturesNV<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub displacement_micromap: Bool32, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for PhysicalDeviceDisplacementMicromapFeaturesNV<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + displacement_micromap: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceDisplacementMicromapFeaturesNV<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_FEATURES_NV; +} +unsafe impl ExtendsPhysicalDeviceFeatures2 for PhysicalDeviceDisplacementMicromapFeaturesNV<'_> {} +unsafe impl ExtendsDeviceCreateInfo for PhysicalDeviceDisplacementMicromapFeaturesNV<'_> {} +impl<'a> PhysicalDeviceDisplacementMicromapFeaturesNV<'a> { + #[inline] + pub fn displacement_micromap(mut self, displacement_micromap: bool) -> Self { + self.displacement_micromap = displacement_micromap.into(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +pub struct PhysicalDeviceDisplacementMicromapPropertiesNV<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub max_displacement_micromap_subdivision_level: u32, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for PhysicalDeviceDisplacementMicromapPropertiesNV<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + max_displacement_micromap_subdivision_level: u32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceDisplacementMicromapPropertiesNV<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_PROPERTIES_NV; +} +unsafe impl ExtendsPhysicalDeviceProperties2 + for PhysicalDeviceDisplacementMicromapPropertiesNV<'_> +{ +} +impl<'a> PhysicalDeviceDisplacementMicromapPropertiesNV<'a> { + #[inline] + pub fn max_displacement_micromap_subdivision_level( + mut self, + max_displacement_micromap_subdivision_level: u32, + ) -> Self { + self.max_displacement_micromap_subdivision_level = + max_displacement_micromap_subdivision_level; + self + } +} +#[repr(C)] +#[derive(Copy, Clone)] +#[doc = ""] +pub struct AccelerationStructureTrianglesDisplacementMicromapNV<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub displacement_bias_and_scale_format: Format, + pub displacement_vector_format: Format, + pub displacement_bias_and_scale_buffer: DeviceOrHostAddressConstKHR, + pub displacement_bias_and_scale_stride: DeviceSize, + pub displacement_vector_buffer: DeviceOrHostAddressConstKHR, + pub displacement_vector_stride: DeviceSize, + pub displaced_micromap_primitive_flags: DeviceOrHostAddressConstKHR, + pub displaced_micromap_primitive_flags_stride: DeviceSize, + pub index_type: IndexType, + pub index_buffer: DeviceOrHostAddressConstKHR, + pub index_stride: DeviceSize, + pub base_triangle: u32, + pub usage_counts_count: u32, + pub p_usage_counts: *const MicromapUsageEXT, + pub pp_usage_counts: *const *const MicromapUsageEXT, + pub micromap: MicromapEXT, + pub _marker: PhantomData<&'a ()>, +} +#[cfg(feature = "debug")] +impl fmt::Debug for AccelerationStructureTrianglesDisplacementMicromapNV<'_> { + fn fmt(&self, fmt: &mut fmt::Formatter) -> fmt::Result { + fmt.debug_struct("AccelerationStructureTrianglesDisplacementMicromapNV") + .field("s_type", &self.s_type) + .field("p_next", &self.p_next) + .field( + "displacement_bias_and_scale_format", + &self.displacement_bias_and_scale_format, + ) + .field( + "displacement_vector_format", + &self.displacement_vector_format, + ) + .field("displacement_bias_and_scale_buffer", &"union") + .field( + "displacement_bias_and_scale_stride", + &self.displacement_bias_and_scale_stride, + ) + .field("displacement_vector_buffer", &"union") + .field( + "displacement_vector_stride", + &self.displacement_vector_stride, + ) + .field("displaced_micromap_primitive_flags", &"union") + .field( + "displaced_micromap_primitive_flags_stride", + &self.displaced_micromap_primitive_flags_stride, + ) + .field("index_type", &self.index_type) + .field("index_buffer", &"union") + .field("index_stride", &self.index_stride) + .field("base_triangle", &self.base_triangle) + .field("usage_counts_count", &self.usage_counts_count) + .field("p_usage_counts", &self.p_usage_counts) + .field("pp_usage_counts", &self.pp_usage_counts) + .field("micromap", &self.micromap) + .finish() + } +} +impl ::std::default::Default for AccelerationStructureTrianglesDisplacementMicromapNV<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + displacement_bias_and_scale_format: Format::default(), + displacement_vector_format: Format::default(), + displacement_bias_and_scale_buffer: DeviceOrHostAddressConstKHR::default(), + displacement_bias_and_scale_stride: DeviceSize::default(), + displacement_vector_buffer: DeviceOrHostAddressConstKHR::default(), + displacement_vector_stride: DeviceSize::default(), + displaced_micromap_primitive_flags: DeviceOrHostAddressConstKHR::default(), + displaced_micromap_primitive_flags_stride: DeviceSize::default(), + index_type: IndexType::default(), + index_buffer: DeviceOrHostAddressConstKHR::default(), + index_stride: DeviceSize::default(), + base_triangle: u32::default(), + usage_counts_count: u32::default(), + p_usage_counts: ::std::ptr::null(), + pp_usage_counts: ::std::ptr::null(), + micromap: MicromapEXT::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for AccelerationStructureTrianglesDisplacementMicromapNV<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::ACCELERATION_STRUCTURE_TRIANGLES_DISPLACEMENT_MICROMAP_NV; +} +unsafe impl ExtendsAccelerationStructureGeometryTrianglesDataKHR + for AccelerationStructureTrianglesDisplacementMicromapNV<'_> +{ +} +impl<'a> AccelerationStructureTrianglesDisplacementMicromapNV<'a> { + #[inline] + pub fn displacement_bias_and_scale_format( + mut self, + displacement_bias_and_scale_format: Format, + ) -> Self { + self.displacement_bias_and_scale_format = displacement_bias_and_scale_format; + self + } + #[inline] + pub fn displacement_vector_format(mut self, displacement_vector_format: Format) -> Self { + self.displacement_vector_format = displacement_vector_format; + self + } + #[inline] + pub fn displacement_bias_and_scale_buffer( + mut self, + displacement_bias_and_scale_buffer: DeviceOrHostAddressConstKHR, + ) -> Self { + self.displacement_bias_and_scale_buffer = displacement_bias_and_scale_buffer; + self + } + #[inline] + pub fn displacement_bias_and_scale_stride( + mut self, + displacement_bias_and_scale_stride: DeviceSize, + ) -> Self { + self.displacement_bias_and_scale_stride = displacement_bias_and_scale_stride; + self + } + #[inline] + pub fn displacement_vector_buffer( + mut self, + displacement_vector_buffer: DeviceOrHostAddressConstKHR, + ) -> Self { + self.displacement_vector_buffer = displacement_vector_buffer; + self + } + #[inline] + pub fn displacement_vector_stride(mut self, displacement_vector_stride: DeviceSize) -> Self { + self.displacement_vector_stride = displacement_vector_stride; + self + } + #[inline] + pub fn displaced_micromap_primitive_flags( + mut self, + displaced_micromap_primitive_flags: DeviceOrHostAddressConstKHR, + ) -> Self { + self.displaced_micromap_primitive_flags = displaced_micromap_primitive_flags; + self + } + #[inline] + pub fn displaced_micromap_primitive_flags_stride( + mut self, + displaced_micromap_primitive_flags_stride: DeviceSize, + ) -> Self { + self.displaced_micromap_primitive_flags_stride = displaced_micromap_primitive_flags_stride; + self + } + #[inline] + pub fn index_type(mut self, index_type: IndexType) -> Self { + self.index_type = index_type; + self + } + #[inline] + pub fn index_buffer(mut self, index_buffer: DeviceOrHostAddressConstKHR) -> Self { + self.index_buffer = index_buffer; + self + } + #[inline] + pub fn index_stride(mut self, index_stride: DeviceSize) -> Self { + self.index_stride = index_stride; + self + } + #[inline] + pub fn base_triangle(mut self, base_triangle: u32) -> Self { + self.base_triangle = base_triangle; + self + } + #[inline] + pub fn usage_counts(mut self, usage_counts: &'a [MicromapUsageEXT]) -> Self { + self.usage_counts_count = usage_counts.len() as _; + self.p_usage_counts = usage_counts.as_ptr(); + self + } + #[inline] + pub fn usage_counts_ptrs(mut self, usage_counts_ptrs: &'a [&'a MicromapUsageEXT]) -> Self { + self.usage_counts_count = usage_counts_ptrs.len() as _; + self.pp_usage_counts = usage_counts_ptrs.as_ptr().cast(); + self + } + #[inline] + pub fn micromap(mut self, micromap: MicromapEXT) -> Self { + self.micromap = micromap; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] #[doc = ""] pub struct PipelinePropertiesIdentifierEXT<'a> { pub s_type: StructureType, @@ -47222,3 +47498,303 @@ impl<'a> MemoryUnmapInfoKHR<'a> { self } } +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +pub struct PhysicalDeviceShaderObjectFeaturesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub shader_object: Bool32, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for PhysicalDeviceShaderObjectFeaturesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + shader_object: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceShaderObjectFeaturesEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::PHYSICAL_DEVICE_SHADER_OBJECT_FEATURES_EXT; +} +unsafe impl ExtendsPhysicalDeviceFeatures2 for PhysicalDeviceShaderObjectFeaturesEXT<'_> {} +unsafe impl ExtendsDeviceCreateInfo for PhysicalDeviceShaderObjectFeaturesEXT<'_> {} +impl<'a> PhysicalDeviceShaderObjectFeaturesEXT<'a> { + #[inline] + pub fn shader_object(mut self, shader_object: bool) -> Self { + self.shader_object = shader_object.into(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +pub struct PhysicalDeviceShaderObjectPropertiesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub shader_binary_uuid: [u8; UUID_SIZE], + pub shader_binary_version: u32, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for PhysicalDeviceShaderObjectPropertiesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + shader_binary_uuid: unsafe { ::std::mem::zeroed() }, + shader_binary_version: u32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceShaderObjectPropertiesEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_SHADER_OBJECT_PROPERTIES_EXT; +} +unsafe impl ExtendsPhysicalDeviceProperties2 for PhysicalDeviceShaderObjectPropertiesEXT<'_> {} +impl<'a> PhysicalDeviceShaderObjectPropertiesEXT<'a> { + #[inline] + pub fn shader_binary_uuid(mut self, shader_binary_uuid: [u8; UUID_SIZE]) -> Self { + self.shader_binary_uuid = shader_binary_uuid; + self + } + #[inline] + pub fn shader_binary_version(mut self, shader_binary_version: u32) -> Self { + self.shader_binary_version = shader_binary_version; + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +pub struct ShaderCreateInfoEXT<'a> { + pub s_type: StructureType, + pub p_next: *const c_void, + pub flags: ShaderCreateFlagsEXT, + pub stage: ShaderStageFlags, + pub next_stage: ShaderStageFlags, + pub code_type: ShaderCodeTypeEXT, + pub code_size: usize, + pub p_code: *const c_void, + pub p_name: *const c_char, + pub set_layout_count: u32, + pub p_set_layouts: *const DescriptorSetLayout, + pub push_constant_range_count: u32, + pub p_push_constant_ranges: *const PushConstantRange, + pub p_specialization_info: *const SpecializationInfo<'a>, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for ShaderCreateInfoEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null(), + flags: ShaderCreateFlagsEXT::default(), + stage: ShaderStageFlags::default(), + next_stage: ShaderStageFlags::default(), + code_type: ShaderCodeTypeEXT::default(), + code_size: usize::default(), + p_code: ::std::ptr::null(), + p_name: ::std::ptr::null(), + set_layout_count: u32::default(), + p_set_layouts: ::std::ptr::null(), + push_constant_range_count: u32::default(), + p_push_constant_ranges: ::std::ptr::null(), + p_specialization_info: ::std::ptr::null(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for ShaderCreateInfoEXT<'a> { + const STRUCTURE_TYPE: StructureType = StructureType::SHADER_CREATE_INFO_EXT; +} +pub unsafe trait ExtendsShaderCreateInfoEXT {} +impl<'a> ShaderCreateInfoEXT<'a> { + #[inline] + pub fn flags(mut self, flags: ShaderCreateFlagsEXT) -> Self { + self.flags = flags; + self + } + #[inline] + pub fn stage(mut self, stage: ShaderStageFlags) -> Self { + self.stage = stage; + self + } + #[inline] + pub fn next_stage(mut self, next_stage: ShaderStageFlags) -> Self { + self.next_stage = next_stage; + self + } + #[inline] + pub fn code_type(mut self, code_type: ShaderCodeTypeEXT) -> Self { + self.code_type = code_type; + self + } + #[inline] + pub fn code(mut self, code: &'a [u8]) -> Self { + self.code_size = code.len(); + self.p_code = code.as_ptr().cast(); + self + } + #[inline] + pub fn name(mut self, name: &'a ::std::ffi::CStr) -> Self { + self.p_name = name.as_ptr(); + self + } + #[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 + } + #[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 + } + #[inline] + pub fn specialization_info(mut self, specialization_info: &'a SpecializationInfo<'a>) -> Self { + self.p_specialization_info = specialization_info; + 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 = ""] +pub struct PhysicalDeviceShaderTileImageFeaturesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub shader_tile_image_color_read_access: Bool32, + pub shader_tile_image_depth_read_access: Bool32, + pub shader_tile_image_stencil_read_access: Bool32, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for PhysicalDeviceShaderTileImageFeaturesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + shader_tile_image_color_read_access: Bool32::default(), + shader_tile_image_depth_read_access: Bool32::default(), + shader_tile_image_stencil_read_access: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceShaderTileImageFeaturesEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_SHADER_TILE_IMAGE_FEATURES_EXT; +} +unsafe impl ExtendsPhysicalDeviceFeatures2 for PhysicalDeviceShaderTileImageFeaturesEXT<'_> {} +unsafe impl ExtendsDeviceCreateInfo for PhysicalDeviceShaderTileImageFeaturesEXT<'_> {} +impl<'a> PhysicalDeviceShaderTileImageFeaturesEXT<'a> { + #[inline] + pub fn shader_tile_image_color_read_access( + mut self, + shader_tile_image_color_read_access: bool, + ) -> Self { + self.shader_tile_image_color_read_access = shader_tile_image_color_read_access.into(); + self + } + #[inline] + pub fn shader_tile_image_depth_read_access( + mut self, + shader_tile_image_depth_read_access: bool, + ) -> Self { + self.shader_tile_image_depth_read_access = shader_tile_image_depth_read_access.into(); + self + } + #[inline] + pub fn shader_tile_image_stencil_read_access( + mut self, + shader_tile_image_stencil_read_access: bool, + ) -> Self { + self.shader_tile_image_stencil_read_access = shader_tile_image_stencil_read_access.into(); + self + } +} +#[repr(C)] +#[cfg_attr(feature = "debug", derive(Debug))] +#[derive(Copy, Clone)] +#[doc = ""] +pub struct PhysicalDeviceShaderTileImagePropertiesEXT<'a> { + pub s_type: StructureType, + pub p_next: *mut c_void, + pub shader_tile_image_coherent_read_accelerated: Bool32, + pub shader_tile_image_read_sample_from_pixel_rate_invocation: Bool32, + pub shader_tile_image_read_from_helper_invocation: Bool32, + pub _marker: PhantomData<&'a ()>, +} +impl ::std::default::Default for PhysicalDeviceShaderTileImagePropertiesEXT<'_> { + #[inline] + fn default() -> Self { + Self { + s_type: Self::STRUCTURE_TYPE, + p_next: ::std::ptr::null_mut(), + shader_tile_image_coherent_read_accelerated: Bool32::default(), + shader_tile_image_read_sample_from_pixel_rate_invocation: Bool32::default(), + shader_tile_image_read_from_helper_invocation: Bool32::default(), + _marker: PhantomData, + } + } +} +unsafe impl<'a> TaggedStructure for PhysicalDeviceShaderTileImagePropertiesEXT<'a> { + const STRUCTURE_TYPE: StructureType = + StructureType::PHYSICAL_DEVICE_SHADER_TILE_IMAGE_PROPERTIES_EXT; +} +unsafe impl ExtendsPhysicalDeviceProperties2 for PhysicalDeviceShaderTileImagePropertiesEXT<'_> {} +impl<'a> PhysicalDeviceShaderTileImagePropertiesEXT<'a> { + #[inline] + pub fn shader_tile_image_coherent_read_accelerated( + mut self, + shader_tile_image_coherent_read_accelerated: bool, + ) -> Self { + self.shader_tile_image_coherent_read_accelerated = + shader_tile_image_coherent_read_accelerated.into(); + self + } + #[inline] + pub fn shader_tile_image_read_sample_from_pixel_rate_invocation( + mut self, + shader_tile_image_read_sample_from_pixel_rate_invocation: bool, + ) -> Self { + self.shader_tile_image_read_sample_from_pixel_rate_invocation = + shader_tile_image_read_sample_from_pixel_rate_invocation.into(); + self + } + #[inline] + pub fn shader_tile_image_read_from_helper_invocation( + mut self, + shader_tile_image_read_from_helper_invocation: bool, + ) -> Self { + self.shader_tile_image_read_from_helper_invocation = + shader_tile_image_read_from_helper_invocation.into(); + self + } +} diff --git a/ash/src/vk/enums.rs b/ash/src/vk/enums.rs index 289b621..6201209 100644 --- a/ash/src/vk/enums.rs +++ b/ash/src/vk/enums.rs @@ -2784,6 +2784,43 @@ impl DeviceFaultVendorBinaryHeaderVersionEXT { impl DeviceFaultVendorBinaryHeaderVersionEXT { pub const ONE: Self = Self(1); } +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Default)] +#[repr(transparent)] +#[doc = ""] +pub struct DisplacementMicromapFormatNV(pub(crate) i32); +impl DisplacementMicromapFormatNV { + #[inline] + pub const fn from_raw(x: i32) -> Self { + Self(x) + } + #[inline] + pub const fn as_raw(self) -> i32 { + self.0 + } +} +impl DisplacementMicromapFormatNV { + pub const TYPE_64_TRIANGLES_64_BYTES: Self = Self(1); + pub const TYPE_256_TRIANGLES_128_BYTES: Self = Self(2); + pub const TYPE_1024_TRIANGLES_128_BYTES: Self = Self(3); +} +#[derive(Clone, Copy, PartialEq, Eq, PartialOrd, Ord, Hash, Default)] +#[repr(transparent)] +#[doc = ""] +pub struct ShaderCodeTypeEXT(pub(crate) i32); +impl ShaderCodeTypeEXT { + #[inline] + pub const fn from_raw(x: i32) -> Self { + Self(x) + } + #[inline] + pub const fn as_raw(self) -> i32 { + self.0 + } +} +impl ShaderCodeTypeEXT { + pub const BINARY: Self = Self(0); + pub const SPIRV: Self = Self(1); +} impl fmt::Debug for ObjectType { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { let name = match *self { @@ -2832,6 +2869,7 @@ impl fmt::Debug for ObjectType { Self::BUFFER_COLLECTION_FUCHSIA => Some("BUFFER_COLLECTION_FUCHSIA"), Self::MICROMAP_EXT => Some("MICROMAP_EXT"), Self::OPTICAL_FLOW_SESSION_NV => Some("OPTICAL_FLOW_SESSION_NV"), + Self::SHADER_EXT => Some("SHADER_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"), @@ -2906,6 +2944,9 @@ impl fmt::Debug for Result { Some("ERROR_INVALID_VIDEO_STD_PARAMETERS_KHR") } Self::ERROR_COMPRESSION_EXHAUSTED_EXT => Some("ERROR_COMPRESSION_EXHAUSTED_EXT"), + Self::ERROR_INCOMPATIBLE_SHADER_BINARY_EXT => { + Some("ERROR_INCOMPATIBLE_SHADER_BINARY_EXT") + } Self::ERROR_OUT_OF_POOL_MEMORY => Some("ERROR_OUT_OF_POOL_MEMORY"), Self::ERROR_INVALID_EXTERNAL_HANDLE => Some("ERROR_INVALID_EXTERNAL_HANDLE"), Self::ERROR_FRAGMENTATION => Some("ERROR_FRAGMENTATION"), diff --git a/ash/src/vk/extensions.rs b/ash/src/vk/extensions.rs index 1fbc1bb..8185d14 100644 --- a/ash/src/vk/extensions.rs +++ b/ash/src/vk/extensions.rs @@ -18312,6 +18312,28 @@ impl KhrPortabilityEnumerationFn { impl InstanceCreateFlags { pub const ENUMERATE_PORTABILITY_KHR: Self = Self(0b1); } +impl ExtShaderTileImageFn { + pub const NAME: &'static ::std::ffi::CStr = + unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"VK_EXT_shader_tile_image\0") }; + pub const SPEC_VERSION: u32 = 1u32; +} +#[derive(Clone)] +pub struct ExtShaderTileImageFn {} +unsafe impl Send for ExtShaderTileImageFn {} +unsafe impl Sync for ExtShaderTileImageFn {} +impl ExtShaderTileImageFn { + pub fn load(mut _f: F) -> Self + where + F: FnMut(&::std::ffi::CStr) -> *const c_void, + { + Self {} + } +} +#[doc = "Generated from 'VK_EXT_shader_tile_image'"] +impl StructureType { + pub const PHYSICAL_DEVICE_SHADER_TILE_IMAGE_FEATURES_EXT: Self = Self(1_000_395_000); + pub const PHYSICAL_DEVICE_SHADER_TILE_IMAGE_PROPERTIES_EXT: Self = Self(1_000_395_001); +} impl ExtOpacityMicromapFn { pub const NAME: &'static ::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"VK_EXT_opacity_micromap\0") }; @@ -18767,6 +18789,43 @@ impl StructureType { pub const MICROMAP_BUILD_SIZES_INFO_EXT: Self = Self(1_000_396_008); pub const ACCELERATION_STRUCTURE_TRIANGLES_OPACITY_MICROMAP_EXT: Self = Self(1_000_396_009); } +impl NvDisplacementMicromapFn { + pub const NAME: &'static ::std::ffi::CStr = unsafe { + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"VK_NV_displacement_micromap\0") + }; + pub const SPEC_VERSION: u32 = 1u32; +} +#[derive(Clone)] +pub struct NvDisplacementMicromapFn {} +unsafe impl Send for NvDisplacementMicromapFn {} +unsafe impl Sync for NvDisplacementMicromapFn {} +impl NvDisplacementMicromapFn { + pub fn load(mut _f: F) -> Self + where + F: FnMut(&::std::ffi::CStr) -> *const c_void, + { + Self {} + } +} +#[doc = "Generated from 'VK_NV_displacement_micromap'"] +impl BuildAccelerationStructureFlagsKHR { + pub const ALLOW_DISPLACEMENT_MICROMAP_UPDATE_NV: Self = Self(0b10_0000_0000); +} +#[doc = "Generated from 'VK_NV_displacement_micromap'"] +impl MicromapTypeEXT { + pub const DISPLACEMENT_MICROMAP_NV: Self = Self(1_000_397_000); +} +#[doc = "Generated from 'VK_NV_displacement_micromap'"] +impl PipelineCreateFlags { + pub const RAY_TRACING_DISPLACEMENT_MICROMAP_NV: Self = + Self(0b1_0000_0000_0000_0000_0000_0000_0000); +} +#[doc = "Generated from 'VK_NV_displacement_micromap'"] +impl StructureType { + pub const PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_FEATURES_NV: Self = Self(1_000_397_000); + pub const PHYSICAL_DEVICE_DISPLACEMENT_MICROMAP_PROPERTIES_NV: Self = Self(1_000_397_001); + pub const ACCELERATION_STRUCTURE_TRIANGLES_DISPLACEMENT_MICROMAP_NV: Self = Self(1_000_397_002); +} impl ExtLoadStoreOpNoneFn { pub const NAME: &'static ::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"VK_EXT_load_store_op_none\0") }; @@ -20862,6 +20921,1194 @@ impl PipelineCreateFlags { impl StructureType { pub const PHYSICAL_DEVICE_PIPELINE_PROTECTED_ACCESS_FEATURES_EXT: Self = Self(1_000_466_000); } +impl ExtShaderObjectFn { + pub const NAME: &'static ::std::ffi::CStr = + unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"VK_EXT_shader_object\0") }; + pub const SPEC_VERSION: u32 = 1u32; +} +#[allow(non_camel_case_types)] +pub type PFN_vkCreateShadersEXT = unsafe extern "system" fn( + device: Device, + create_info_count: u32, + p_create_infos: *const ShaderCreateInfoEXT, + p_allocator: *const AllocationCallbacks, + p_shaders: *mut ShaderEXT, +) -> Result; +#[allow(non_camel_case_types)] +pub type PFN_vkDestroyShaderEXT = unsafe extern "system" fn( + device: Device, + shader: ShaderEXT, + p_allocator: *const AllocationCallbacks, +); +#[allow(non_camel_case_types)] +pub type PFN_vkGetShaderBinaryDataEXT = unsafe extern "system" fn( + device: Device, + shader: ShaderEXT, + p_data_size: *mut usize, + p_data: *mut c_void, +) -> Result; +#[allow(non_camel_case_types)] +pub type PFN_vkCmdBindShadersEXT = unsafe extern "system" fn( + command_buffer: CommandBuffer, + stage_count: u32, + p_stages: *const ShaderStageFlags, + p_shaders: *const ShaderEXT, +); +#[derive(Clone)] +pub struct ExtShaderObjectFn { + pub create_shaders_ext: PFN_vkCreateShadersEXT, + pub destroy_shader_ext: PFN_vkDestroyShaderEXT, + pub get_shader_binary_data_ext: PFN_vkGetShaderBinaryDataEXT, + pub cmd_bind_shaders_ext: PFN_vkCmdBindShadersEXT, + pub cmd_set_cull_mode_ext: crate::vk::PFN_vkCmdSetCullMode, + pub cmd_set_front_face_ext: crate::vk::PFN_vkCmdSetFrontFace, + pub cmd_set_primitive_topology_ext: crate::vk::PFN_vkCmdSetPrimitiveTopology, + pub cmd_set_viewport_with_count_ext: crate::vk::PFN_vkCmdSetViewportWithCount, + pub cmd_set_scissor_with_count_ext: crate::vk::PFN_vkCmdSetScissorWithCount, + pub cmd_bind_vertex_buffers2_ext: crate::vk::PFN_vkCmdBindVertexBuffers2, + pub cmd_set_depth_test_enable_ext: crate::vk::PFN_vkCmdSetDepthTestEnable, + pub cmd_set_depth_write_enable_ext: crate::vk::PFN_vkCmdSetDepthWriteEnable, + pub cmd_set_depth_compare_op_ext: crate::vk::PFN_vkCmdSetDepthCompareOp, + pub cmd_set_depth_bounds_test_enable_ext: crate::vk::PFN_vkCmdSetDepthBoundsTestEnable, + pub cmd_set_stencil_test_enable_ext: crate::vk::PFN_vkCmdSetStencilTestEnable, + pub cmd_set_stencil_op_ext: crate::vk::PFN_vkCmdSetStencilOp, + pub cmd_set_vertex_input_ext: crate::vk::PFN_vkCmdSetVertexInputEXT, + pub cmd_set_patch_control_points_ext: crate::vk::PFN_vkCmdSetPatchControlPointsEXT, + pub cmd_set_rasterizer_discard_enable_ext: crate::vk::PFN_vkCmdSetRasterizerDiscardEnable, + pub cmd_set_depth_bias_enable_ext: crate::vk::PFN_vkCmdSetDepthBiasEnable, + pub cmd_set_logic_op_ext: crate::vk::PFN_vkCmdSetLogicOpEXT, + pub cmd_set_primitive_restart_enable_ext: crate::vk::PFN_vkCmdSetPrimitiveRestartEnable, + pub cmd_set_tessellation_domain_origin_ext: crate::vk::PFN_vkCmdSetTessellationDomainOriginEXT, + pub cmd_set_depth_clamp_enable_ext: crate::vk::PFN_vkCmdSetDepthClampEnableEXT, + pub cmd_set_polygon_mode_ext: crate::vk::PFN_vkCmdSetPolygonModeEXT, + pub cmd_set_rasterization_samples_ext: crate::vk::PFN_vkCmdSetRasterizationSamplesEXT, + pub cmd_set_sample_mask_ext: crate::vk::PFN_vkCmdSetSampleMaskEXT, + pub cmd_set_alpha_to_coverage_enable_ext: crate::vk::PFN_vkCmdSetAlphaToCoverageEnableEXT, + pub cmd_set_alpha_to_one_enable_ext: crate::vk::PFN_vkCmdSetAlphaToOneEnableEXT, + pub cmd_set_logic_op_enable_ext: crate::vk::PFN_vkCmdSetLogicOpEnableEXT, + pub cmd_set_color_blend_enable_ext: crate::vk::PFN_vkCmdSetColorBlendEnableEXT, + pub cmd_set_color_blend_equation_ext: crate::vk::PFN_vkCmdSetColorBlendEquationEXT, + pub cmd_set_color_write_mask_ext: crate::vk::PFN_vkCmdSetColorWriteMaskEXT, + pub cmd_set_rasterization_stream_ext: crate::vk::PFN_vkCmdSetRasterizationStreamEXT, + pub cmd_set_conservative_rasterization_mode_ext: + crate::vk::PFN_vkCmdSetConservativeRasterizationModeEXT, + pub cmd_set_extra_primitive_overestimation_size_ext: + crate::vk::PFN_vkCmdSetExtraPrimitiveOverestimationSizeEXT, + pub cmd_set_depth_clip_enable_ext: crate::vk::PFN_vkCmdSetDepthClipEnableEXT, + pub cmd_set_sample_locations_enable_ext: crate::vk::PFN_vkCmdSetSampleLocationsEnableEXT, + pub cmd_set_color_blend_advanced_ext: crate::vk::PFN_vkCmdSetColorBlendAdvancedEXT, + pub cmd_set_provoking_vertex_mode_ext: crate::vk::PFN_vkCmdSetProvokingVertexModeEXT, + pub cmd_set_line_rasterization_mode_ext: crate::vk::PFN_vkCmdSetLineRasterizationModeEXT, + pub cmd_set_line_stipple_enable_ext: crate::vk::PFN_vkCmdSetLineStippleEnableEXT, + pub cmd_set_depth_clip_negative_one_to_one_ext: + crate::vk::PFN_vkCmdSetDepthClipNegativeOneToOneEXT, + pub cmd_set_viewport_w_scaling_enable_nv: crate::vk::PFN_vkCmdSetViewportWScalingEnableNV, + pub cmd_set_viewport_swizzle_nv: crate::vk::PFN_vkCmdSetViewportSwizzleNV, + pub cmd_set_coverage_to_color_enable_nv: crate::vk::PFN_vkCmdSetCoverageToColorEnableNV, + pub cmd_set_coverage_to_color_location_nv: crate::vk::PFN_vkCmdSetCoverageToColorLocationNV, + pub cmd_set_coverage_modulation_mode_nv: crate::vk::PFN_vkCmdSetCoverageModulationModeNV, + pub cmd_set_coverage_modulation_table_enable_nv: + crate::vk::PFN_vkCmdSetCoverageModulationTableEnableNV, + pub cmd_set_coverage_modulation_table_nv: crate::vk::PFN_vkCmdSetCoverageModulationTableNV, + pub cmd_set_shading_rate_image_enable_nv: crate::vk::PFN_vkCmdSetShadingRateImageEnableNV, + pub cmd_set_representative_fragment_test_enable_nv: + crate::vk::PFN_vkCmdSetRepresentativeFragmentTestEnableNV, + pub cmd_set_coverage_reduction_mode_nv: crate::vk::PFN_vkCmdSetCoverageReductionModeNV, +} +unsafe impl Send for ExtShaderObjectFn {} +unsafe impl Sync for ExtShaderObjectFn {} +impl ExtShaderObjectFn { + pub fn load(mut _f: F) -> Self + where + F: FnMut(&::std::ffi::CStr) -> *const c_void, + { + Self { + create_shaders_ext: unsafe { + unsafe extern "system" fn create_shaders_ext( + _device: Device, + _create_info_count: u32, + _p_create_infos: *const ShaderCreateInfoEXT, + _p_allocator: *const AllocationCallbacks, + _p_shaders: *mut ShaderEXT, + ) -> Result { + panic!(concat!("Unable to load ", stringify!(create_shaders_ext))) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCreateShadersEXT\0"); + let val = _f(cname); + if val.is_null() { + create_shaders_ext + } else { + ::std::mem::transmute(val) + } + }, + destroy_shader_ext: unsafe { + unsafe extern "system" fn destroy_shader_ext( + _device: Device, + _shader: ShaderEXT, + _p_allocator: *const AllocationCallbacks, + ) { + panic!(concat!("Unable to load ", stringify!(destroy_shader_ext))) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkDestroyShaderEXT\0"); + let val = _f(cname); + if val.is_null() { + destroy_shader_ext + } else { + ::std::mem::transmute(val) + } + }, + get_shader_binary_data_ext: unsafe { + unsafe extern "system" fn get_shader_binary_data_ext( + _device: Device, + _shader: ShaderEXT, + _p_data_size: *mut usize, + _p_data: *mut c_void, + ) -> Result { + panic!(concat!( + "Unable to load ", + stringify!(get_shader_binary_data_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkGetShaderBinaryDataEXT\0"); + let val = _f(cname); + if val.is_null() { + get_shader_binary_data_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_bind_shaders_ext: unsafe { + unsafe extern "system" fn cmd_bind_shaders_ext( + _command_buffer: CommandBuffer, + _stage_count: u32, + _p_stages: *const ShaderStageFlags, + _p_shaders: *const ShaderEXT, + ) { + panic!(concat!("Unable to load ", stringify!(cmd_bind_shaders_ext))) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdBindShadersEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_bind_shaders_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_cull_mode_ext: unsafe { + unsafe extern "system" fn cmd_set_cull_mode_ext( + _command_buffer: CommandBuffer, + _cull_mode: CullModeFlags, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_cull_mode_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetCullModeEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_cull_mode_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_front_face_ext: unsafe { + unsafe extern "system" fn cmd_set_front_face_ext( + _command_buffer: CommandBuffer, + _front_face: FrontFace, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_front_face_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetFrontFaceEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_front_face_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_primitive_topology_ext: unsafe { + unsafe extern "system" fn cmd_set_primitive_topology_ext( + _command_buffer: CommandBuffer, + _primitive_topology: PrimitiveTopology, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_primitive_topology_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetPrimitiveTopologyEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_primitive_topology_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_viewport_with_count_ext: unsafe { + unsafe extern "system" fn cmd_set_viewport_with_count_ext( + _command_buffer: CommandBuffer, + _viewport_count: u32, + _p_viewports: *const Viewport, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_viewport_with_count_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetViewportWithCountEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_viewport_with_count_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_scissor_with_count_ext: unsafe { + unsafe extern "system" fn cmd_set_scissor_with_count_ext( + _command_buffer: CommandBuffer, + _scissor_count: u32, + _p_scissors: *const Rect2D, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_scissor_with_count_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetScissorWithCountEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_scissor_with_count_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_bind_vertex_buffers2_ext: unsafe { + unsafe extern "system" fn cmd_bind_vertex_buffers2_ext( + _command_buffer: CommandBuffer, + _first_binding: u32, + _binding_count: u32, + _p_buffers: *const Buffer, + _p_offsets: *const DeviceSize, + _p_sizes: *const DeviceSize, + _p_strides: *const DeviceSize, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_bind_vertex_buffers2_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdBindVertexBuffers2EXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_bind_vertex_buffers2_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_test_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_test_enable_ext( + _command_buffer: CommandBuffer, + _depth_test_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_test_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthTestEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_test_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_write_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_write_enable_ext( + _command_buffer: CommandBuffer, + _depth_write_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_write_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthWriteEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_write_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_compare_op_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_compare_op_ext( + _command_buffer: CommandBuffer, + _depth_compare_op: CompareOp, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_compare_op_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetDepthCompareOpEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_compare_op_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_bounds_test_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_bounds_test_enable_ext( + _command_buffer: CommandBuffer, + _depth_bounds_test_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_bounds_test_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthBoundsTestEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_bounds_test_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_stencil_test_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_stencil_test_enable_ext( + _command_buffer: CommandBuffer, + _stencil_test_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_stencil_test_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetStencilTestEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_stencil_test_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_stencil_op_ext: unsafe { + unsafe extern "system" fn cmd_set_stencil_op_ext( + _command_buffer: CommandBuffer, + _face_mask: StencilFaceFlags, + _fail_op: StencilOp, + _pass_op: StencilOp, + _depth_fail_op: StencilOp, + _compare_op: CompareOp, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_stencil_op_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetStencilOpEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_stencil_op_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_vertex_input_ext: unsafe { + unsafe extern "system" fn cmd_set_vertex_input_ext( + _command_buffer: CommandBuffer, + _vertex_binding_description_count: u32, + _p_vertex_binding_descriptions: *const VertexInputBindingDescription2EXT, + _vertex_attribute_description_count: u32, + _p_vertex_attribute_descriptions: *const VertexInputAttributeDescription2EXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_vertex_input_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetVertexInputEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_vertex_input_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_patch_control_points_ext: unsafe { + unsafe extern "system" fn cmd_set_patch_control_points_ext( + _command_buffer: CommandBuffer, + _patch_control_points: u32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_patch_control_points_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetPatchControlPointsEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_patch_control_points_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_rasterizer_discard_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_rasterizer_discard_enable_ext( + _command_buffer: CommandBuffer, + _rasterizer_discard_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_rasterizer_discard_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetRasterizerDiscardEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_rasterizer_discard_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_bias_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_bias_enable_ext( + _command_buffer: CommandBuffer, + _depth_bias_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_bias_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthBiasEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_bias_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_logic_op_ext: unsafe { + unsafe extern "system" fn cmd_set_logic_op_ext( + _command_buffer: CommandBuffer, + _logic_op: LogicOp, + ) { + panic!(concat!("Unable to load ", stringify!(cmd_set_logic_op_ext))) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetLogicOpEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_logic_op_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_primitive_restart_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_primitive_restart_enable_ext( + _command_buffer: CommandBuffer, + _primitive_restart_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_primitive_restart_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetPrimitiveRestartEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_primitive_restart_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_tessellation_domain_origin_ext: unsafe { + unsafe extern "system" fn cmd_set_tessellation_domain_origin_ext( + _command_buffer: CommandBuffer, + _domain_origin: TessellationDomainOrigin, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_tessellation_domain_origin_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetTessellationDomainOriginEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_tessellation_domain_origin_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_clamp_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_clamp_enable_ext( + _command_buffer: CommandBuffer, + _depth_clamp_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_clamp_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthClampEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_clamp_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_polygon_mode_ext: unsafe { + unsafe extern "system" fn cmd_set_polygon_mode_ext( + _command_buffer: CommandBuffer, + _polygon_mode: PolygonMode, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_polygon_mode_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetPolygonModeEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_polygon_mode_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_rasterization_samples_ext: unsafe { + unsafe extern "system" fn cmd_set_rasterization_samples_ext( + _command_buffer: CommandBuffer, + _rasterization_samples: SampleCountFlags, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_rasterization_samples_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetRasterizationSamplesEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_rasterization_samples_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_sample_mask_ext: unsafe { + unsafe extern "system" fn cmd_set_sample_mask_ext( + _command_buffer: CommandBuffer, + _samples: SampleCountFlags, + _p_sample_mask: *const SampleMask, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_sample_mask_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetSampleMaskEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_sample_mask_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_alpha_to_coverage_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_alpha_to_coverage_enable_ext( + _command_buffer: CommandBuffer, + _alpha_to_coverage_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_alpha_to_coverage_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetAlphaToCoverageEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_alpha_to_coverage_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_alpha_to_one_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_alpha_to_one_enable_ext( + _command_buffer: CommandBuffer, + _alpha_to_one_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_alpha_to_one_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetAlphaToOneEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_alpha_to_one_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_logic_op_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_logic_op_enable_ext( + _command_buffer: CommandBuffer, + _logic_op_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_logic_op_enable_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetLogicOpEnableEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_logic_op_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_color_blend_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_color_blend_enable_ext( + _command_buffer: CommandBuffer, + _first_attachment: u32, + _attachment_count: u32, + _p_color_blend_enables: *const Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_color_blend_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetColorBlendEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_color_blend_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_color_blend_equation_ext: unsafe { + unsafe extern "system" fn cmd_set_color_blend_equation_ext( + _command_buffer: CommandBuffer, + _first_attachment: u32, + _attachment_count: u32, + _p_color_blend_equations: *const ColorBlendEquationEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_color_blend_equation_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetColorBlendEquationEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_color_blend_equation_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_color_write_mask_ext: unsafe { + unsafe extern "system" fn cmd_set_color_write_mask_ext( + _command_buffer: CommandBuffer, + _first_attachment: u32, + _attachment_count: u32, + _p_color_write_masks: *const ColorComponentFlags, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_color_write_mask_ext) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetColorWriteMaskEXT\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_color_write_mask_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_rasterization_stream_ext: unsafe { + unsafe extern "system" fn cmd_set_rasterization_stream_ext( + _command_buffer: CommandBuffer, + _rasterization_stream: u32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_rasterization_stream_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetRasterizationStreamEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_rasterization_stream_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_conservative_rasterization_mode_ext: unsafe { + unsafe extern "system" fn cmd_set_conservative_rasterization_mode_ext( + _command_buffer: CommandBuffer, + _conservative_rasterization_mode: ConservativeRasterizationModeEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_conservative_rasterization_mode_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetConservativeRasterizationModeEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_conservative_rasterization_mode_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_extra_primitive_overestimation_size_ext: unsafe { + unsafe extern "system" fn cmd_set_extra_primitive_overestimation_size_ext( + _command_buffer: CommandBuffer, + _extra_primitive_overestimation_size: f32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_extra_primitive_overestimation_size_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetExtraPrimitiveOverestimationSizeEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_extra_primitive_overestimation_size_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_clip_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_clip_enable_ext( + _command_buffer: CommandBuffer, + _depth_clip_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_clip_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthClipEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_clip_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_sample_locations_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_sample_locations_enable_ext( + _command_buffer: CommandBuffer, + _sample_locations_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_sample_locations_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetSampleLocationsEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_sample_locations_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_color_blend_advanced_ext: unsafe { + unsafe extern "system" fn cmd_set_color_blend_advanced_ext( + _command_buffer: CommandBuffer, + _first_attachment: u32, + _attachment_count: u32, + _p_color_blend_advanced: *const ColorBlendAdvancedEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_color_blend_advanced_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetColorBlendAdvancedEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_color_blend_advanced_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_provoking_vertex_mode_ext: unsafe { + unsafe extern "system" fn cmd_set_provoking_vertex_mode_ext( + _command_buffer: CommandBuffer, + _provoking_vertex_mode: ProvokingVertexModeEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_provoking_vertex_mode_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetProvokingVertexModeEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_provoking_vertex_mode_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_line_rasterization_mode_ext: unsafe { + unsafe extern "system" fn cmd_set_line_rasterization_mode_ext( + _command_buffer: CommandBuffer, + _line_rasterization_mode: LineRasterizationModeEXT, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_line_rasterization_mode_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetLineRasterizationModeEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_line_rasterization_mode_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_line_stipple_enable_ext: unsafe { + unsafe extern "system" fn cmd_set_line_stipple_enable_ext( + _command_buffer: CommandBuffer, + _stippled_line_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_line_stipple_enable_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetLineStippleEnableEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_line_stipple_enable_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_depth_clip_negative_one_to_one_ext: unsafe { + unsafe extern "system" fn cmd_set_depth_clip_negative_one_to_one_ext( + _command_buffer: CommandBuffer, + _negative_one_to_one: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_depth_clip_negative_one_to_one_ext) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetDepthClipNegativeOneToOneEXT\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_depth_clip_negative_one_to_one_ext + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_viewport_w_scaling_enable_nv: unsafe { + unsafe extern "system" fn cmd_set_viewport_w_scaling_enable_nv( + _command_buffer: CommandBuffer, + _viewport_w_scaling_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_viewport_w_scaling_enable_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetViewportWScalingEnableNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_viewport_w_scaling_enable_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_viewport_swizzle_nv: unsafe { + unsafe extern "system" fn cmd_set_viewport_swizzle_nv( + _command_buffer: CommandBuffer, + _first_viewport: u32, + _viewport_count: u32, + _p_viewport_swizzles: *const ViewportSwizzleNV, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_viewport_swizzle_nv) + )) + } + let cname = + ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"vkCmdSetViewportSwizzleNV\0"); + let val = _f(cname); + if val.is_null() { + cmd_set_viewport_swizzle_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_coverage_to_color_enable_nv: unsafe { + unsafe extern "system" fn cmd_set_coverage_to_color_enable_nv( + _command_buffer: CommandBuffer, + _coverage_to_color_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_coverage_to_color_enable_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetCoverageToColorEnableNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_coverage_to_color_enable_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_coverage_to_color_location_nv: unsafe { + unsafe extern "system" fn cmd_set_coverage_to_color_location_nv( + _command_buffer: CommandBuffer, + _coverage_to_color_location: u32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_coverage_to_color_location_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetCoverageToColorLocationNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_coverage_to_color_location_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_coverage_modulation_mode_nv: unsafe { + unsafe extern "system" fn cmd_set_coverage_modulation_mode_nv( + _command_buffer: CommandBuffer, + _coverage_modulation_mode: CoverageModulationModeNV, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_coverage_modulation_mode_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetCoverageModulationModeNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_coverage_modulation_mode_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_coverage_modulation_table_enable_nv: unsafe { + unsafe extern "system" fn cmd_set_coverage_modulation_table_enable_nv( + _command_buffer: CommandBuffer, + _coverage_modulation_table_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_coverage_modulation_table_enable_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetCoverageModulationTableEnableNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_coverage_modulation_table_enable_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_coverage_modulation_table_nv: unsafe { + unsafe extern "system" fn cmd_set_coverage_modulation_table_nv( + _command_buffer: CommandBuffer, + _coverage_modulation_table_count: u32, + _p_coverage_modulation_table: *const f32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_coverage_modulation_table_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetCoverageModulationTableNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_coverage_modulation_table_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_shading_rate_image_enable_nv: unsafe { + unsafe extern "system" fn cmd_set_shading_rate_image_enable_nv( + _command_buffer: CommandBuffer, + _shading_rate_image_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_shading_rate_image_enable_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetShadingRateImageEnableNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_shading_rate_image_enable_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_representative_fragment_test_enable_nv: unsafe { + unsafe extern "system" fn cmd_set_representative_fragment_test_enable_nv( + _command_buffer: CommandBuffer, + _representative_fragment_test_enable: Bool32, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_representative_fragment_test_enable_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetRepresentativeFragmentTestEnableNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_representative_fragment_test_enable_nv + } else { + ::std::mem::transmute(val) + } + }, + cmd_set_coverage_reduction_mode_nv: unsafe { + unsafe extern "system" fn cmd_set_coverage_reduction_mode_nv( + _command_buffer: CommandBuffer, + _coverage_reduction_mode: CoverageReductionModeNV, + ) { + panic!(concat!( + "Unable to load ", + stringify!(cmd_set_coverage_reduction_mode_nv) + )) + } + let cname = ::std::ffi::CStr::from_bytes_with_nul_unchecked( + b"vkCmdSetCoverageReductionModeNV\0", + ); + let val = _f(cname); + if val.is_null() { + cmd_set_coverage_reduction_mode_nv + } else { + ::std::mem::transmute(val) + } + }, + } + } +} +#[doc = "Generated from 'VK_EXT_shader_object'"] +impl ObjectType { + pub const SHADER_EXT: Self = Self(1_000_482_000); +} +#[doc = "Generated from 'VK_EXT_shader_object'"] +impl Result { + pub const ERROR_INCOMPATIBLE_SHADER_BINARY_EXT: Self = Self(1_000_482_000); +} +#[doc = "Generated from 'VK_EXT_shader_object'"] +impl StructureType { + pub const PHYSICAL_DEVICE_SHADER_OBJECT_FEATURES_EXT: Self = Self(1_000_482_000); + pub const PHYSICAL_DEVICE_SHADER_OBJECT_PROPERTIES_EXT: Self = Self(1_000_482_001); + pub const SHADER_CREATE_INFO_EXT: Self = Self(1_000_482_002); + pub const SHADER_REQUIRED_SUBGROUP_SIZE_CREATE_INFO_EXT: Self = + Self::PIPELINE_SHADER_STAGE_REQUIRED_SUBGROUP_SIZE_CREATE_INFO; +} impl QcomTilePropertiesFn { pub const NAME: &'static ::std::ffi::CStr = unsafe { ::std::ffi::CStr::from_bytes_with_nul_unchecked(b"VK_QCOM_tile_properties\0") }; diff --git a/ash/src/vk/native.rs b/ash/src/vk/native.rs index 1a6b58d..03e0ad5 100644 --- a/ash/src/vk/native.rs +++ b/ash/src/vk/native.rs @@ -1,4 +1,4 @@ -/* automatically generated by rust-bindgen 0.63.0 */ +/* automatically generated by rust-bindgen 0.64.0 */ #[repr(C)] #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] diff --git a/generator/Cargo.toml b/generator/Cargo.toml index ec45261..8df2ba1 100644 --- a/generator/Cargo.toml +++ b/generator/Cargo.toml @@ -5,7 +5,7 @@ authors = ["Maik Klein "] edition = "2021" [dependencies] -bindgen = "0.63" +bindgen = "0.64" heck = "0.4" itertools = "0.10" nom = "7.1" diff --git a/generator/Vulkan-Headers b/generator/Vulkan-Headers index fa204df..63af1cf 160000 --- a/generator/Vulkan-Headers +++ b/generator/Vulkan-Headers @@ -1 +1 @@ -Subproject commit fa204df59c6caea6b9be3cf0754a88cd89056a87 +Subproject commit 63af1cf1ee906ba4dcd5a324bdd0201d4f4bfd12