[x265] [X265][PATCH] Fix: Access violation when aqMode=0 + qgSize=8

Niranjan Bala niranjan at multicorewareinc.com
Tue Jan 19 03:54:05 UTC 2021


>From c0947ffa313365f68f85b1f988e0521327d71a75 Mon Sep 17 00:00:00 2001
From: Niranjan <niranjan at multicorewareinc.com>
Date: Wed, 13 Jan 2021 20:27:02 +0530
Subject: [PATCH] Fix: Access violation when aqMode=0 + qgSize=8

---
 source/common/lowres.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/source/common/lowres.cpp b/source/common/lowres.cpp
index 578981d64..334640ec9 100644
--- a/source/common/lowres.cpp
+++ b/source/common/lowres.cpp
@@ -73,7 +73,7 @@ bool Lowres::create(x265_param* param, PicYuv *origPic,
uint32_t qgSize)

     size_t planesize = lumaStride * (lines + 2 * origPic->m_lumaMarginY);
     size_t padoffset = lumaStride * origPic->m_lumaMarginY +
origPic->m_lumaMarginX;
-    if (!!param->rc.aqMode || !!param->rc.hevcAq || !!param->bAQMotion)
+    if (!!param->rc.aqMode || !!param->rc.hevcAq || !!param->bAQMotion ||
!!param->bEnableWeightedPred || !!param->bEnableWeightedBiPred)
     {
         CHECKED_MALLOC_ZERO(qpAqOffset, double, cuCountFullRes);
         CHECKED_MALLOC_ZERO(invQscaleFactor, int, cuCountFullRes);
-- 
2.18.0.windows.1


-- 

Thanks & Regards
*Niranjan Kumar B*
Video Codec Engineer
Media & AI Analytics
+91 958 511 1449
<https://multicorewareinc.com/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/x265-devel/attachments/20210119/7ef4b6f6/attachment.html>


More information about the x265-devel mailing list