diff --git a/wgpu-hal/src/vulkan/device.rs b/wgpu-hal/src/vulkan/device.rs index c1efa3a1b0c..d2f4674a31a 100644 --- a/wgpu-hal/src/vulkan/device.rs +++ b/wgpu-hal/src/vulkan/device.rs @@ -713,11 +713,11 @@ impl super::Device { } /// # Safety - /// + /// The `d3d11_shared_handle` must be valid and respecting `desc`. #[cfg(windows)] pub unsafe fn texture_from_d3d11_shared_handle( &self, - d3d11_shared_handle: vk::HANDLE, + d3d11_shared_handle: *mut std::ffi::c_void, desc: &crate::TextureDescriptor, ) -> ash::prelude::VkResult { let copy_size = desc.copy_extent(); @@ -776,7 +776,7 @@ impl super::Device { let mut import_memory_info = vk::ImportMemoryWin32HandleInfoKHR::default() .handle_type(vk::ExternalMemoryHandleTypeFlags::D3D11_TEXTURE_KMT) - .handle(d3d11_shared_handle); + .handle(d3d11_shared_handle as _); let Some(mem_type_index) = self .find_memory_type_index(req.memory_type_bits, vk::MemoryPropertyFlags::DEVICE_LOCAL)