diff --git a/ash/Cargo.toml b/ash/Cargo.toml index dd42f8d..411af2f 100644 --- a/ash/Cargo.toml +++ b/ash/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ash" -version = "0.18.4" +version = "0.18.5" authors = ["maik klein "] description = "Vulkan bindings for Rust" license = "MIT" diff --git a/ash/src/device.rs b/ash/src/device.rs index 1156b7a..8d8b9eb 100644 --- a/ash/src/device.rs +++ b/ash/src/device.rs @@ -941,6 +941,34 @@ pub trait DeviceV1_0 { self.fp_v1_0().unmap_memory(self.handle(), memory); } + unsafe fn invalidate_mapped_memory_ranges(&self, ranges: &[vk::MappedMemoryRange]) + -> VkResult<()> + { + let err_code = self.fp_v1_0().invalidate_mapped_memory_ranges( + self.handle(), + ranges.len() as vk::uint32_t, + ranges.as_ptr() + ); + match err_code { + vk::Result::Success => Ok(()), + _ => Err(err_code), + } + } + + unsafe fn flush_mapped_memory_ranges(&self, ranges: &[vk::MappedMemoryRange]) + -> VkResult<()> + { + let err_code = self.fp_v1_0().flush_mapped_memory_ranges( + self.handle(), + ranges.len() as vk::uint32_t, + ranges.as_ptr() + ); + match err_code { + vk::Result::Success => Ok(()), + _ => Err(err_code), + } + } + unsafe fn create_framebuffer( &self, create_info: &vk::FramebufferCreateInfo,