From a187a4931a966ffbb80a23c63ff39c43f15264b3 Mon Sep 17 00:00:00 2001 From: "Dr. Chat" Date: Wed, 25 May 2016 13:14:03 -0500 Subject: [PATCH] Whoops - fix setting the wrong host base for some graphics allocations. --- src/xenia/ui/vulkan/circular_buffer.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/xenia/ui/vulkan/circular_buffer.cc b/src/xenia/ui/vulkan/circular_buffer.cc index 883e4d98d..94d2996ce 100644 --- a/src/xenia/ui/vulkan/circular_buffer.cc +++ b/src/xenia/ui/vulkan/circular_buffer.cc @@ -103,6 +103,7 @@ bool CircularBuffer::CanAcquire(VkDeviceSize length) { length = xe::round_up(length, alignment_); if (allocations_.empty()) { // Read head has caught up to write head (entire buffer available for write) + assert_true(read_head_ == write_head_); return capacity_ >= length; } else if (write_head_ < read_head_) { // Write head wrapped around and is behind read head. @@ -167,7 +168,7 @@ CircularBuffer::Allocation* CircularBuffer::Acquire( } else if ((read_head_ - 0) >= aligned_length) { // Free space from begin -> read auto alloc = new Allocation(); - alloc->host_ptr = host_base_ + write_head_; + alloc->host_ptr = host_base_ + 0; alloc->gpu_memory = gpu_memory_; alloc->offset = gpu_base_ + 0; alloc->length = length;