[SCM] libav/experimental: fixing RGB32->RGB16 on big endian patch by (Colin Leroy <colin at colino dot net>)
siretart at users.alioth.debian.org
siretart at users.alioth.debian.org
Sun Jun 30 15:33:44 UTC 2013
The following commit has been merged in the experimental branch:
commit 470ba6f28a020d23beae561b18f1d413ce339256
Author: Colin Leroy <colin at colino.net>
Date: Wed Oct 23 23:52:57 2002 +0000
fixing RGB32->RGB16 on big endian patch by (Colin Leroy <colin at colino dot net>)
Originally committed as revision 7892 to svn://svn.mplayerhq.hu/mplayer/trunk/postproc
diff --git a/postproc/rgb2rgb_template.c b/postproc/rgb2rgb_template.c
index 44e764e..887856d 100644
--- a/postproc/rgb2rgb_template.c
+++ b/postproc/rgb2rgb_template.c
@@ -364,11 +364,20 @@ static inline void RENAME(rgb32to16)(const uint8_t *src, uint8_t *dst, unsigned
#endif
while(s < end)
{
+#ifndef WORDS_BIGENDIAN
const int b= *s++;
const int g= *s++;
const int r= *s++;
+#else
+ const int a= *s++; /*skip*/
+ const int r= *s++;
+ const int g= *s++;
+ const int b= *s++;
+#endif
*d++ = (b>>3) | ((g&0xFC)<<3) | ((r&0xF8)<<8);
+#ifndef WORDS_BIGENDIAN
s++;
+#endif
}
}
--
Libav/FFmpeg packaging
More information about the pkg-multimedia-commits
mailing list