[x265] [PATCH] fix for bug in lambda computaion code
sumalatha at multicorewareinc.com
sumalatha at multicorewareinc.com
Wed Sep 4 11:40:51 CEST 2013
# HG changeset patch
# User sumalatha
# Date 1378287645 -19800
# Node ID dd65a897f560491a2f442d14679259a04b4754f2
# Parent f2cdc2762beec1afc5eee9f3ee3de02f107451af
fix for bug in lambda computaion code
diff -r f2cdc2762bee -r dd65a897f560 source/Lib/TLibEncoder/TEncTop.cpp
--- a/source/Lib/TLibEncoder/TEncTop.cpp Wed Sep 04 13:41:08 2013 +0530
+++ b/source/Lib/TLibEncoder/TEncTop.cpp Wed Sep 04 15:10:45 2013 +0530
@@ -843,11 +843,11 @@
double lambda = 0;
if(slice->getSliceType() == I_SLICE)
{
- lambda = X265_MIN(1,x265_lambda2_tab_I[qp]);
+ lambda = X265_MAX(1,x265_lambda2_tab_I[qp]);
}
else
{
- lambda = X265_MIN(1,x265_lambda2_non_I[qp]);
+ lambda = X265_MAX(1,x265_lambda2_non_I[qp]);
}
// for RDO
diff -r f2cdc2762bee -r dd65a897f560 source/encoder/frameencoder.cpp
--- a/source/encoder/frameencoder.cpp Wed Sep 04 13:41:08 2013 +0530
+++ b/source/encoder/frameencoder.cpp Wed Sep 04 15:10:45 2013 +0530
@@ -297,11 +297,11 @@
int qp = X265_MAX(-m_sps.getQpBDOffsetY(), X265_MIN(MAX_QP, (int)floor(qpdouble + 0.5)));
if(slice->getSliceType() == I_SLICE)
{
- lambda = X265_MIN(1,x265_lambda2_tab_I[qp]);
+ lambda = X265_MAX(1,x265_lambda2_tab_I[qp]);
}
else
{
- lambda = X265_MIN(1,x265_lambda2_non_I[qp]);
+ lambda = X265_MAX(1,x265_lambda2_non_I[qp]);
}
// for RDO
More information about the x265-devel
mailing list