summaryrefslogtreecommitdiffstats
path: root/src/video_core/host1x
diff options
context:
space:
mode:
authorameerj <52414509+ameerj@users.noreply.github.com>2022-12-20 04:40:50 +0100
committerameerj <52414509+ameerj@users.noreply.github.com>2022-12-20 04:40:50 +0100
commitc6590ad07b384762fd90ee8852796ec681a69286 (patch)
treec0d8d2d157f3bb4be01331f2da459c0f68ca4d7b /src/video_core/host1x
parenttests: Add ScratchBuffer tests (diff)
downloadyuzu-c6590ad07b384762fd90ee8852796ec681a69286.tar
yuzu-c6590ad07b384762fd90ee8852796ec681a69286.tar.gz
yuzu-c6590ad07b384762fd90ee8852796ec681a69286.tar.bz2
yuzu-c6590ad07b384762fd90ee8852796ec681a69286.tar.lz
yuzu-c6590ad07b384762fd90ee8852796ec681a69286.tar.xz
yuzu-c6590ad07b384762fd90ee8852796ec681a69286.tar.zst
yuzu-c6590ad07b384762fd90ee8852796ec681a69286.zip
Diffstat (limited to 'src/video_core/host1x')
-rw-r--r--src/video_core/host1x/vic.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/video_core/host1x/vic.cpp b/src/video_core/host1x/vic.cpp
index ac0b7d20e..36a04e4e0 100644
--- a/src/video_core/host1x/vic.cpp
+++ b/src/video_core/host1x/vic.cpp
@@ -155,7 +155,7 @@ void Vic::WriteRGBFrame(const AVFrame* frame, const VicConfig& config) {
// swizzle pitch linear to block linear
const u32 block_height = static_cast<u32>(config.block_linear_height_log2);
const auto size = Texture::CalculateSize(true, 4, width, height, 1, block_height, 0);
- luma_buffer.resize(size);
+ luma_buffer.resize_destructive(size);
std::span<const u8> frame_buff(converted_frame_buf_addr, 4 * width * height);
Texture::SwizzleSubrect(luma_buffer, frame_buff, 4, width, height, 1, 0, 0, width, height,
block_height, 0, width * 4);
@@ -181,8 +181,8 @@ void Vic::WriteYUVFrame(const AVFrame* frame, const VicConfig& config) {
const auto stride = static_cast<size_t>(frame->linesize[0]);
- luma_buffer.resize(aligned_width * surface_height);
- chroma_buffer.resize(aligned_width * surface_height / 2);
+ luma_buffer.resize_destructive(aligned_width * surface_height);
+ chroma_buffer.resize_destructive(aligned_width * surface_height / 2);
// Populate luma buffer
const u8* luma_src = frame->data[0];