1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229
#[doc = "<s>Vulkan Manual Page</s> · Constant"] #[doc(alias = "VK_FUCHSIA_EXTERNAL_SEMAPHORE_SPEC_VERSION")] pub const FUCHSIA_EXTERNAL_SEMAPHORE_SPEC_VERSION: u32 = 1; #[doc = "<s>Vulkan Manual Page</s> · Constant"] #[doc(alias = "VK_FUCHSIA_EXTERNAL_SEMAPHORE_EXTENSION_NAME")] pub const FUCHSIA_EXTERNAL_SEMAPHORE_EXTENSION_NAME: *const std::os::raw::c_char = crate::cstr!("VK_FUCHSIA_external_semaphore"); #[doc = "<s>Vulkan Manual Page</s> · Constant"] pub const FN_GET_SEMAPHORE_ZIRCON_HANDLE_FUCHSIA: *const std::os::raw::c_char = crate::cstr!("vkGetSemaphoreZirconHandleFUCHSIA"); #[doc = "<s>Vulkan Manual Page</s> · Constant"] pub const FN_IMPORT_SEMAPHORE_ZIRCON_HANDLE_FUCHSIA: *const std::os::raw::c_char = crate::cstr!("vkImportSemaphoreZirconHandleFUCHSIA"); #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/vkGetSemaphoreZirconHandleFUCHSIA.html) · Function"] #[allow(non_camel_case_types)] pub type PFN_vkGetSemaphoreZirconHandleFUCHSIA = unsafe extern "system" fn( device: crate::vk1_0::Device, p_get_zircon_handle_info: *const crate::extensions::fuchsia_external_semaphore::SemaphoreGetZirconHandleInfoFUCHSIA, p_zircon_handle: *mut *mut std::ffi::c_void, ) -> crate::vk1_0::Result; #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/vkImportSemaphoreZirconHandleFUCHSIA.html) · Function"] #[allow(non_camel_case_types)] pub type PFN_vkImportSemaphoreZirconHandleFUCHSIA = unsafe extern "system" fn( device: crate::vk1_0::Device, p_import_semaphore_zircon_handle_info: *const crate::extensions::fuchsia_external_semaphore::ImportSemaphoreZirconHandleInfoFUCHSIA, ) -> crate::vk1_0::Result; #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkImportSemaphoreZirconHandleInfoFUCHSIA.html) · Structure"] #[doc(alias = "VkImportSemaphoreZirconHandleInfoFUCHSIA")] #[derive(Copy, Clone)] #[repr(C)] pub struct ImportSemaphoreZirconHandleInfoFUCHSIA { pub s_type: crate::vk1_0::StructureType, pub p_next: *const std::ffi::c_void, pub semaphore: crate::vk1_0::Semaphore, pub flags: crate::vk1_1::SemaphoreImportFlags, pub handle_type: crate::vk1_1::ExternalSemaphoreHandleTypeFlagBits, pub zircon_handle: *mut std::ffi::c_void, } impl Default for ImportSemaphoreZirconHandleInfoFUCHSIA { fn default() -> Self { Self { s_type: crate::vk1_0::StructureType::IMPORT_SEMAPHORE_ZIRCON_HANDLE_INFO_FUCHSIA, p_next: std::ptr::null(), semaphore: Default::default(), flags: Default::default(), handle_type: Default::default(), zircon_handle: std::ptr::null_mut(), } } } impl std::fmt::Debug for ImportSemaphoreZirconHandleInfoFUCHSIA { fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { f.debug_struct("ImportSemaphoreZirconHandleInfoFUCHSIA") .field("s_type", &self.s_type) .field("p_next", &self.p_next) .field("semaphore", &self.semaphore) .field("flags", &self.flags) .field("handle_type", &self.handle_type) .field("zircon_handle", &self.zircon_handle) .finish() } } impl ImportSemaphoreZirconHandleInfoFUCHSIA { #[inline] pub fn into_builder<'a>(self) -> ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { ImportSemaphoreZirconHandleInfoFUCHSIABuilder(self, std::marker::PhantomData) } } #[derive(Copy, Clone)] #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkImportSemaphoreZirconHandleInfoFUCHSIA.html) · Builder of [`ImportSemaphoreZirconHandleInfoFUCHSIA`]"] #[repr(transparent)] pub struct ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a>(ImportSemaphoreZirconHandleInfoFUCHSIA, std::marker::PhantomData<&'a ()>); impl<'a> ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { #[inline] pub fn new() -> ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { ImportSemaphoreZirconHandleInfoFUCHSIABuilder(Default::default(), std::marker::PhantomData) } #[inline] pub fn semaphore(mut self, semaphore: crate::vk1_0::Semaphore) -> Self { self.0.semaphore = semaphore as _; self } #[inline] pub fn flags(mut self, flags: crate::vk1_1::SemaphoreImportFlags) -> Self { self.0.flags = flags as _; self } #[inline] pub fn handle_type(mut self, handle_type: crate::vk1_1::ExternalSemaphoreHandleTypeFlagBits) -> Self { self.0.handle_type = handle_type as _; self } #[inline] pub fn zircon_handle(mut self, zircon_handle: *mut std::ffi::c_void) -> Self { self.0.zircon_handle = zircon_handle; self } #[inline] #[doc = "Discards all lifetime information. Use the `Deref` and `DerefMut` implementations if possible."] pub fn build(self) -> ImportSemaphoreZirconHandleInfoFUCHSIA { self.0 } } impl<'a> std::default::Default for ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { fn default() -> ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { Self::new() } } impl<'a> std::fmt::Debug for ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { std::fmt::Debug::fmt(&self.0, f) } } impl<'a> std::ops::Deref for ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { type Target = ImportSemaphoreZirconHandleInfoFUCHSIA; fn deref(&self) -> &Self::Target { &self.0 } } impl<'a> std::ops::DerefMut for ImportSemaphoreZirconHandleInfoFUCHSIABuilder<'a> { fn deref_mut(&mut self) -> &mut Self::Target { &mut self.0 } } #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkSemaphoreGetZirconHandleInfoFUCHSIA.html) · Structure"] #[doc(alias = "VkSemaphoreGetZirconHandleInfoFUCHSIA")] #[derive(Copy, Clone)] #[repr(C)] pub struct SemaphoreGetZirconHandleInfoFUCHSIA { pub s_type: crate::vk1_0::StructureType, pub p_next: *const std::ffi::c_void, pub semaphore: crate::vk1_0::Semaphore, pub handle_type: crate::vk1_1::ExternalSemaphoreHandleTypeFlagBits, } impl Default for SemaphoreGetZirconHandleInfoFUCHSIA { fn default() -> Self { Self { s_type: crate::vk1_0::StructureType::SEMAPHORE_GET_ZIRCON_HANDLE_INFO_FUCHSIA, p_next: std::ptr::null(), semaphore: Default::default(), handle_type: Default::default(), } } } impl std::fmt::Debug for SemaphoreGetZirconHandleInfoFUCHSIA { fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { f.debug_struct("SemaphoreGetZirconHandleInfoFUCHSIA") .field("s_type", &self.s_type) .field("p_next", &self.p_next) .field("semaphore", &self.semaphore) .field("handle_type", &self.handle_type) .finish() } } impl SemaphoreGetZirconHandleInfoFUCHSIA { #[inline] pub fn into_builder<'a>(self) -> SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { SemaphoreGetZirconHandleInfoFUCHSIABuilder(self, std::marker::PhantomData) } } #[derive(Copy, Clone)] #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/VkSemaphoreGetZirconHandleInfoFUCHSIA.html) · Builder of [`SemaphoreGetZirconHandleInfoFUCHSIA`]"] #[repr(transparent)] pub struct SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a>(SemaphoreGetZirconHandleInfoFUCHSIA, std::marker::PhantomData<&'a ()>); impl<'a> SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { #[inline] pub fn new() -> SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { SemaphoreGetZirconHandleInfoFUCHSIABuilder(Default::default(), std::marker::PhantomData) } #[inline] pub fn semaphore(mut self, semaphore: crate::vk1_0::Semaphore) -> Self { self.0.semaphore = semaphore as _; self } #[inline] pub fn handle_type(mut self, handle_type: crate::vk1_1::ExternalSemaphoreHandleTypeFlagBits) -> Self { self.0.handle_type = handle_type as _; self } #[inline] #[doc = "Discards all lifetime information. Use the `Deref` and `DerefMut` implementations if possible."] pub fn build(self) -> SemaphoreGetZirconHandleInfoFUCHSIA { self.0 } } impl<'a> std::default::Default for SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { fn default() -> SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { Self::new() } } impl<'a> std::fmt::Debug for SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result { std::fmt::Debug::fmt(&self.0, f) } } impl<'a> std::ops::Deref for SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { type Target = SemaphoreGetZirconHandleInfoFUCHSIA; fn deref(&self) -> &Self::Target { &self.0 } } impl<'a> std::ops::DerefMut for SemaphoreGetZirconHandleInfoFUCHSIABuilder<'a> { fn deref_mut(&mut self) -> &mut Self::Target { &mut self.0 } } #[doc = "Provided by [`crate::extensions::fuchsia_external_semaphore`]"] impl crate::DeviceLoader { #[inline] #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/vkGetSemaphoreZirconHandleFUCHSIA.html) · Function"] #[doc(alias = "vkGetSemaphoreZirconHandleFUCHSIA")] pub unsafe fn get_semaphore_zircon_handle_fuchsia( &self, get_zircon_handle_info: &crate::extensions::fuchsia_external_semaphore::SemaphoreGetZirconHandleInfoFUCHSIA, zircon_handle: *mut *mut std::ffi::c_void, ) -> crate::utils::VulkanResult<()> { let _function = self.get_semaphore_zircon_handle_fuchsia.expect("`get_semaphore_zircon_handle_fuchsia` is not loaded"); let _return = _function(self.handle, get_zircon_handle_info as _, zircon_handle); crate::utils::VulkanResult::new(_return, ()) } #[inline] #[doc = "[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.2-extensions/man/html/vkImportSemaphoreZirconHandleFUCHSIA.html) · Function"] #[doc(alias = "vkImportSemaphoreZirconHandleFUCHSIA")] pub unsafe fn import_semaphore_zircon_handle_fuchsia( &self, import_semaphore_zircon_handle_info: &crate::extensions::fuchsia_external_semaphore::ImportSemaphoreZirconHandleInfoFUCHSIA, ) -> crate::utils::VulkanResult<()> { let _function = self.import_semaphore_zircon_handle_fuchsia.expect("`import_semaphore_zircon_handle_fuchsia` is not loaded"); let _return = _function(self.handle, import_semaphore_zircon_handle_info as _); crate::utils::VulkanResult::new(_return, ()) } }