[x265] [PATCH 2 of 4] optimize: use UChar on g_convertToBit to avoid signed extend

Min Chen chenm003 at 163.com
Wed Mar 12 19:03:22 CET 2014


# HG changeset patch
# User Min Chen <chenm003 at 163.com>
# Date 1394647292 25200
# Node ID 265ddf73f344ba41fdb885a8b40795b4fb453f48
# Parent  7b671ec7308cad5e6995e2d9721840994e9c92a3
optimize: use UChar on g_convertToBit to avoid signed extend

diff -r 7b671ec7308c -r 265ddf73f344 source/Lib/TLibCommon/TComRom.cpp
--- a/source/Lib/TLibCommon/TComRom.cpp	Wed Mar 12 11:01:09 2014 -0700
+++ b/source/Lib/TLibCommon/TComRom.cpp	Wed Mar 12 11:01:32 2014 -0700
@@ -418,7 +418,7 @@
 // Misc.
 // ====================================================================================================================
 
-char g_convertToBit[MAX_CU_SIZE + 1];
+UChar g_convertToBit[MAX_CU_SIZE + 1];
 
 #if ENC_DEC_TRACE
 FILE*  g_hTrace = NULL;
diff -r 7b671ec7308c -r 265ddf73f344 source/Lib/TLibCommon/TComRom.h
--- a/source/Lib/TLibCommon/TComRom.h	Wed Mar 12 11:01:09 2014 -0700
+++ b/source/Lib/TLibCommon/TComRom.h	Wed Mar 12 11:01:32 2014 -0700
@@ -153,7 +153,7 @@
 // Misc.
 // ====================================================================================================================
 
-extern char g_convertToBit[MAX_CU_SIZE + 1]; // from width to log2(width)-2
+extern UChar g_convertToBit[MAX_CU_SIZE + 1]; // from width to log2(width)-2
 
 #ifndef ENC_DEC_TRACE
 # define ENC_DEC_TRACE 0



More information about the x265-devel mailing list