#[doc(alias = "VK_KHR_DEFERRED_HOST_OPERATIONS_SPEC_VERSION")]
pub const KHR_DEFERRED_HOST_OPERATIONS_SPEC_VERSION: u32 = 4;
#[doc(alias = "VK_KHR_DEFERRED_HOST_OPERATIONS_EXTENSION_NAME")]
pub const KHR_DEFERRED_HOST_OPERATIONS_EXTENSION_NAME: *const std::os::raw::c_char = crate::cstr!(
"VK_KHR_deferred_host_operations"
);
pub const FN_CREATE_DEFERRED_OPERATION_KHR: *const std::os::raw::c_char = crate::cstr!(
"vkCreateDeferredOperationKHR"
);
pub const FN_DESTROY_DEFERRED_OPERATION_KHR: *const std::os::raw::c_char = crate::cstr!(
"vkDestroyDeferredOperationKHR"
);
pub const FN_GET_DEFERRED_OPERATION_MAX_CONCURRENCY_KHR: *const std::os::raw::c_char = crate::cstr!(
"vkGetDeferredOperationMaxConcurrencyKHR"
);
pub const FN_GET_DEFERRED_OPERATION_RESULT_KHR: *const std::os::raw::c_char = crate::cstr!(
"vkGetDeferredOperationResultKHR"
);
pub const FN_DEFERRED_OPERATION_JOIN_KHR: *const std::os::raw::c_char = crate::cstr!(
"vkDeferredOperationJoinKHR"
);
crate::non_dispatchable_handle!(
DeferredOperationKHR, DEFERRED_OPERATION_KHR,
"[Vulkan Manual Page](https://www.khronos.org/registry/vulkan/specs/1.3-extensions/man/html/VkDeferredOperationKHR.html) · Non-dispatchable Handle",
"VkDeferredOperationKHR"
);
impl crate::vk1_0::Result {
pub const THREAD_IDLE_KHR: Self = Self(1000268000);
pub const THREAD_DONE_KHR: Self = Self(1000268001);
pub const OPERATION_DEFERRED_KHR: Self = Self(1000268002);
pub const OPERATION_NOT_DEFERRED_KHR: Self = Self(1000268003);
}
impl crate::vk1_0::ObjectType {
pub const DEFERRED_OPERATION_KHR: Self = Self(1000268000);
}
#[allow(non_camel_case_types)]
pub type PFN_vkCreateDeferredOperationKHR = unsafe extern "system" fn(
device: crate::vk1_0::Device,
p_allocator: *const crate::vk1_0::AllocationCallbacks,
p_deferred_operation: *mut crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> crate::vk1_0::Result;
#[allow(non_camel_case_types)]
pub type PFN_vkDestroyDeferredOperationKHR = unsafe extern "system" fn(
device: crate::vk1_0::Device,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
p_allocator: *const crate::vk1_0::AllocationCallbacks,
) -> ();
#[allow(non_camel_case_types)]
pub type PFN_vkGetDeferredOperationMaxConcurrencyKHR = unsafe extern "system" fn(
device: crate::vk1_0::Device,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> u32;
#[allow(non_camel_case_types)]
pub type PFN_vkGetDeferredOperationResultKHR = unsafe extern "system" fn(
device: crate::vk1_0::Device,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> crate::vk1_0::Result;
#[allow(non_camel_case_types)]
pub type PFN_vkDeferredOperationJoinKHR = unsafe extern "system" fn(
device: crate::vk1_0::Device,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> crate::vk1_0::Result;
impl crate::DeviceLoader {
#[inline]
#[track_caller]
#[doc(alias = "vkCreateDeferredOperationKHR")]
pub unsafe fn create_deferred_operation_khr(
&self,
allocator: Option<&crate::vk1_0::AllocationCallbacks>,
) -> crate::utils::VulkanResult<
crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
> {
let _function = self
.create_deferred_operation_khr
.expect(crate::NOT_LOADED_MESSAGE);
let mut deferred_operation = Default::default();
let _return = _function(
self.handle,
match allocator {
Some(v) => v,
None => std::ptr::null(),
},
&mut deferred_operation,
);
crate::utils::VulkanResult::new(_return, deferred_operation)
}
#[inline]
#[track_caller]
#[doc(alias = "vkDestroyDeferredOperationKHR")]
pub unsafe fn destroy_deferred_operation_khr(
&self,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
allocator: Option<&crate::vk1_0::AllocationCallbacks>,
) -> () {
let _function = self
.destroy_deferred_operation_khr
.expect(crate::NOT_LOADED_MESSAGE);
let _return = _function(
self.handle,
operation as _,
match allocator {
Some(v) => v,
None => std::ptr::null(),
},
);
()
}
#[inline]
#[track_caller]
#[doc(alias = "vkGetDeferredOperationMaxConcurrencyKHR")]
pub unsafe fn get_deferred_operation_max_concurrency_khr(
&self,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> u32 {
let _function = self
.get_deferred_operation_max_concurrency_khr
.expect(crate::NOT_LOADED_MESSAGE);
let _return = _function(self.handle, operation as _);
_return
}
#[inline]
#[track_caller]
#[doc(alias = "vkGetDeferredOperationResultKHR")]
pub unsafe fn get_deferred_operation_result_khr(
&self,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> crate::utils::VulkanResult<()> {
let _function = self
.get_deferred_operation_result_khr
.expect(crate::NOT_LOADED_MESSAGE);
let _return = _function(self.handle, operation as _);
crate::utils::VulkanResult::new(_return, ())
}
#[inline]
#[track_caller]
#[doc(alias = "vkDeferredOperationJoinKHR")]
pub unsafe fn deferred_operation_join_khr(
&self,
operation: crate::extensions::khr_deferred_host_operations::DeferredOperationKHR,
) -> crate::utils::VulkanResult<()> {
let _function = self
.deferred_operation_join_khr
.expect(crate::NOT_LOADED_MESSAGE);
let _return = _function(self.handle, operation as _);
crate::utils::VulkanResult::new(_return, ())
}
}