diff postproc/rgb2rgb_template.c @ 12385:b5c106b694e4

this isn't actually stupid, but it's not valid C and gcc 3.5 rejects it as such
author rfelker
date Sat, 01 May 2004 20:15:21 +0000
parents 3254b413ef1c
children b969547bb0b1
line wrap: on
line diff
--- a/postproc/rgb2rgb_template.c	Sat May 01 20:00:04 2004 +0000
+++ b/postproc/rgb2rgb_template.c	Sat May 01 20:15:21 2004 +0000
@@ -388,7 +388,7 @@
 #endif
 	while(s < end)
 	{
-		const int src= *((uint32_t*)s)++;
+		const int src= *s; s += 4;
 		*d++ = ((src&0xFF)>>3) + ((src&0xFC00)>>5) + ((src&0xF80000)>>8);
 //		*d++ = ((src>>3)&0x1F) + ((src>>5)&0x7E0) + ((src>>8)&0xF800);
 	}
@@ -450,7 +450,7 @@
 #endif
 	while(s < end)
 	{
-		const int src= *((uint32_t*)s)++;
+		const int src= *s; s += 4;
 		*d++ = ((src&0xF8)<<8) + ((src&0xFC00)>>5) + ((src&0xF80000)>>19);
 	}
 }
@@ -546,7 +546,7 @@
 #endif
 	while(s < end)
 	{
-		const int src= *((uint32_t*)s)++;
+		const int src= *s; s += 4;
 		*d++ = ((src&0xFF)>>3) + ((src&0xF800)>>6) + ((src&0xF80000)>>9);
 	}
 }
@@ -607,7 +607,7 @@
 #endif
 	while(s < end)
 	{
-		const int src= *((uint32_t*)s)++;
+		const int src= *s; s += 4;
 		*d++ = ((src&0xF8)<<7) + ((src&0xF800)>>6) + ((src&0xF80000)>>19);
 	}
 }