mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-19 18:04:56 +00:00
video_core: texture_cache: proper UniqueImage
class movers
This commit is contained in:
parent
a67b8f7a0b
commit
055dec1149
1 changed files with 6 additions and 1 deletions
|
@ -53,9 +53,14 @@ struct UniqueImage {
|
||||||
UniqueImage(const UniqueImage&) = delete;
|
UniqueImage(const UniqueImage&) = delete;
|
||||||
UniqueImage& operator=(const UniqueImage&) = delete;
|
UniqueImage& operator=(const UniqueImage&) = delete;
|
||||||
|
|
||||||
UniqueImage(UniqueImage&& other) : image{std::exchange(other.image, VK_NULL_HANDLE)} {}
|
UniqueImage(UniqueImage&& other)
|
||||||
|
: image{std::exchange(other.image, VK_NULL_HANDLE)},
|
||||||
|
allocator{std::exchange(other.allocator, VK_NULL_HANDLE)},
|
||||||
|
allocation{std::exchange(other.allocation, VK_NULL_HANDLE)} {}
|
||||||
UniqueImage& operator=(UniqueImage&& other) {
|
UniqueImage& operator=(UniqueImage&& other) {
|
||||||
image = std::exchange(other.image, VK_NULL_HANDLE);
|
image = std::exchange(other.image, VK_NULL_HANDLE);
|
||||||
|
allocator = std::exchange(other.allocator, VK_NULL_HANDLE);
|
||||||
|
allocation = std::exchange(other.allocation, VK_NULL_HANDLE);
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue