[xiph-commits] r3829 - liboggplay/trunk/src/liboggplay
oggk at svn.annodex.net
oggk at svn.annodex.net
Mon Dec 15 12:14:16 PST 2008
Author: oggk
Date: 2008-12-15 12:14:15 -0800 (Mon, 15 Dec 2008)
New Revision: 3829
Modified:
liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c
Log:
do not trash the buffer pointer, it's not nice to others who might
want to use it after you.
Modified: liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c
===================================================================
--- liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c 2008-12-15 18:53:44 UTC (rev 3828)
+++ liboggplay/trunk/src/liboggplay/oggplay_yuv2rgb.c 2008-12-15 20:14:15 UTC (rev 3829)
@@ -73,6 +73,7 @@
unsigned char * restrict ptry;
unsigned char * restrict ptru;
unsigned char * restrict ptrv;
+ unsigned char * ptro;
register __m64 *y, *o;
register __m64 zero, ut, vt, imm, imm2;
@@ -81,14 +82,15 @@
zero = _mm_setzero_si64();
+ ptro = rgb->ptro;
ptry = yuv->ptry;
ptru = yuv->ptru;
ptrv = yuv->ptrv;
for (i = 0; i < yuv->y_height; i++) {
int j;
- o = (__m64*)rgb->ptro;
- rgb->ptro += rgb->rgb_width * 4;
+ o = (__m64*)ptro;
+ ptro += rgb->rgb_width * 4;
for (j = 0; j < yuv->y_width; j += 8) {
y = (__m64*)&ptry[j];
@@ -203,6 +205,7 @@
unsigned char * restrict ptry;
unsigned char * restrict ptru;
unsigned char * restrict ptrv;
+ unsigned char * ptro;
register __m64 *y, *o;
register __m64 zero, ut, vt, imm, imm2;
@@ -214,11 +217,12 @@
ptry = yuv->ptry;
ptru = yuv->ptru;
ptrv = yuv->ptrv;
+ ptro = rgb->ptro;
for (i = 0; i < yuv->y_height; i++) {
int j;
- o = (__m64*)rgb->ptro;
- rgb->ptro += rgb->rgb_width * 4;
+ o = (__m64*)ptro;
+ ptro += rgb->rgb_width * 4;
for (j = 0; j < yuv->y_width; j += 8) {
y = (__m64*)&ptry[j];
More information about the commits
mailing list