Merge pull request #11854 from TellowKrinkle/AMDFix

VideoBackends:Metal: Allocate bounding box uploads on a cpu buffer
This commit is contained in:
OatmealDome 2023-06-02 06:17:44 +02:00 committed by GitHub
commit 7bbd530eb5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -54,8 +54,7 @@ void Metal::BoundingBox::Write(u32 index, const std::vector<BBoxType>& values)
{
@autoreleasepool
{
StateTracker::Map map = g_state_tracker->Allocate(StateTracker::UploadBuffer::Other, size,
StateTracker::AlignMask::Other);
StateTracker::Map map = g_state_tracker->AllocateForTextureUpload(size);
memcpy(map.cpu_buffer, values.data(), size);
g_state_tracker->EndRenderPass();
id<MTLBlitCommandEncoder> upload = [g_state_tracker->GetRenderCmdBuf() blitCommandEncoder];