mirror of
				https://git.zaroz.cloud/nintendo-back-up/yuzu/yuzu-mainline.git
				synced 2025-03-21 01:53:15 +00:00 
			
		
		
		
	renderer_vulkan/wrapper: Add buffer and image handles
This commit is contained in:
		
							parent
							
								
									d85ca0ab33
								
							
						
					
					
						commit
						affee77b70
					
				@ -420,4 +420,12 @@ std::vector<VkCheckpointDataNV> Queue::GetCheckpointDataNV(const DeviceDispatch&
 | 
			
		||||
    return checkpoints;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
void Buffer::BindMemory(VkDeviceMemory memory, VkDeviceSize offset) const {
 | 
			
		||||
    Check(dld->vkBindBufferMemory(owner, handle, memory, offset));
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
void Image::BindMemory(VkDeviceMemory memory, VkDeviceSize offset) const {
 | 
			
		||||
    Check(dld->vkBindImageMemory(owner, handle, memory, offset));
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
} // namespace Vulkan::vk
 | 
			
		||||
 | 
			
		||||
@ -584,4 +584,20 @@ private:
 | 
			
		||||
    const DeviceDispatch* dld = nullptr;
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
class Buffer : public Handle<VkBuffer, VkDevice, DeviceDispatch> {
 | 
			
		||||
    using Handle<VkBuffer, VkDevice, DeviceDispatch>::Handle;
 | 
			
		||||
 | 
			
		||||
public:
 | 
			
		||||
    /// Attaches a memory allocation.
 | 
			
		||||
    void BindMemory(VkDeviceMemory memory, VkDeviceSize offset) const;
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
class Image : public Handle<VkImage, VkDevice, DeviceDispatch> {
 | 
			
		||||
    using Handle<VkImage, VkDevice, DeviceDispatch>::Handle;
 | 
			
		||||
 | 
			
		||||
public:
 | 
			
		||||
    /// Attaches a memory allocation.
 | 
			
		||||
    void BindMemory(VkDeviceMemory memory, VkDeviceSize offset) const;
 | 
			
		||||
};
 | 
			
		||||
 | 
			
		||||
} // namespace Vulkan::vk
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user