[xiph-commits] r7827 - trunk/oggdsf/src/lib/codecs/theora/filters/dsfTheoraEncoder

illiminable at motherfish-iii.xiph.org illiminable at motherfish-iii.xiph.org
Wed Sep 22 03:57:59 PDT 2004


Author: illiminable
Date: 2004-09-22 03:57:59 -0700 (Wed, 22 Sep 2004)
New Revision: 7827

Modified:
   trunk/oggdsf/src/lib/codecs/theora/filters/dsfTheoraEncoder/TheoraEncodeInputPin.cpp
Log:
* Slight optimisation to integerised RGBxx to AYUV conversion.

Modified: trunk/oggdsf/src/lib/codecs/theora/filters/dsfTheoraEncoder/TheoraEncodeInputPin.cpp
===================================================================
--- trunk/oggdsf/src/lib/codecs/theora/filters/dsfTheoraEncoder/TheoraEncodeInputPin.cpp	2004-09-22 10:50:26 UTC (rev 7826)
+++ trunk/oggdsf/src/lib/codecs/theora/filters/dsfTheoraEncoder/TheoraEncodeInputPin.cpp	2004-09-22 10:57:59 UTC (rev 7827)
@@ -476,8 +476,8 @@
 		locL += KR * (locR);					//Red
 
 		
-		*(locDestPtr++) = CLIP3(0, 255, ((112 * ( (65536*locR) - locL)) / V_FACTOR) + 128);			//V for Victor
-		*(locDestPtr++) = CLIP3(0, 255, ((112 * ( (65536*locB) - locL)) / U_FACTOR) + 128);			//U for ugly
+		*(locDestPtr++) = CLIP3(0, 255, ((112 * ( (locR<<16) - locL)) / V_FACTOR) + 128);			//V for Victor
+		*(locDestPtr++) = CLIP3(0, 255, ((112 * ( (locB<<16) - locL)) / U_FACTOR) + 128);			//U for ugly
 		*(locDestPtr++) = CLIP3(0, 255, locL >> 16);												//Y for yellow
 		*(locDestPtr++) = locSourcePtr[3];																		//A for alpha
 



More information about the commits mailing list