[x265] [PATCH] Cleanup xITransformSkip function

praveen at multicorewareinc.com praveen at multicorewareinc.com
Tue Jul 9 11:53:21 CEST 2013


# HG changeset patch
# User praveentiwari
# Date 1373363590 -19800
# Node ID 5f59172660590a9f99081211e7eb84410a509301
# Parent  ac3db95e6f384f1a5f4c0349dd41a0dcf9f3e287
Cleanup xITransformSkip function

diff -r ac3db95e6f38 -r 5f5917266059 source/Lib/TLibCommon/TComTrQuant.cpp
--- a/source/Lib/TLibCommon/TComTrQuant.cpp	Tue Jul 09 15:13:36 2013 +0530
+++ b/source/Lib/TLibCommon/TComTrQuant.cpp	Tue Jul 09 15:23:10 2013 +0530
@@ -1119,11 +1119,11 @@
  *  \param uiStride stride of input residual data
  *  \param iSize transform size (iSize x iSize)
  */
-Void TComTrQuant::xITransformSkip(Int bitDepth, Int* plCoef, Short* pResidual, UInt uiStride, Int width, Int height)
+Void TComTrQuant::xITransformSkip(Int bitDepth, Int* coef, Short* residual, UInt stride, Int width, Int height)
 {
     assert(width == height);
-    UInt uiLog2TrSize = g_aucConvertToBit[width] + 2;
-    Int  shift = MAX_TR_DYNAMIC_RANGE - bitDepth - uiLog2TrSize;
+    UInt log2TrSize = g_aucConvertToBit[width] + 2;
+    Int  shift = MAX_TR_DYNAMIC_RANGE - bitDepth - log2TrSize;
     UInt transformSkipShift;
     Int  j, k;
     if (shift > 0)
@@ -1131,7 +1131,7 @@
         transformSkipShift = shift;
         for (j = 0; j < height; j++)
         {
-            x265::primitives.cvt32to16_shr(&pResidual[j * uiStride], &plCoef[j * width], shift, width);
+            x265::primitives.cvt32to16_shr(&residual[j * stride], &coef[j * width], shift, width);
         }
     }
     else
@@ -1142,7 +1142,7 @@
         {
             for (k = 0; k < width; k++)
             {
-                pResidual[j * uiStride + k] =  plCoef[j * width + k] << transformSkipShift;
+                residual[j * stride + k] =  coef[j * width + k] << transformSkipShift;
             }
         }
     }


More information about the x265-devel mailing list