]> git.sesse.net Git - vlc/commitdiff
* *.h: shut up gcc (cast of lvalue).
authorLaurent Aimar <fenrir@videolan.org>
Mon, 29 Mar 2004 19:57:07 +0000 (19:57 +0000)
committerLaurent Aimar <fenrir@videolan.org>
Mon, 29 Mar 2004 19:57:07 +0000 (19:57 +0000)
modules/video_chroma/i420_rgb.h
modules/video_chroma/i420_yuy2.h
modules/video_chroma/i422_yuy2.h

index a61b14ada9d1877ebbe21a8af502e41559fa256c..f1afa773dd16b4c5bd81dafe6b89c652f7b5c80c 100644 (file)
@@ -2,7 +2,7 @@
  * i420_rgb.h : YUV to bitmap RGB conversion module for vlc
  *****************************************************************************
  * Copyright (C) 2000, 2004 VideoLAN
- * $Id: i420_rgb.h,v 1.5 2004/01/31 05:53:35 rocky Exp $
+ * $Id$
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -186,13 +186,13 @@ void E_(I420_RGB32)        ( vout_thread_t *, picture_t *, picture_t * );
         {                                                                     \
             *p_pic++ = *p_buffer;   p_buffer += *p_offset++;                  \
         }                                                                     \
-        (uint8_t*)p_pic += i_right_margin;                                    \
+        p_pic = (void*)((uint8_t*)p_pic + i_right_margin );                   \
     }                                                                         \
     else                                                                      \
     {                                                                         \
         /* No scaling, conversion has been done directly in picture memory.   \
          * Increment of picture pointer to end of line is still needed */     \
-        (uint8_t*)p_pic += p_dest->p->i_pitch;                                \
+        p_pic = (void*)((uint8_t*)p_pic + p_dest->p->i_pitch );               \
     }                                                                         \
 
 /*****************************************************************************
@@ -224,7 +224,7 @@ void E_(I420_RGB32)        ( vout_thread_t *, picture_t *, picture_t * );
         }                                                                     \
     }                                                                         \
     /* Increment of picture pointer to end of line is still needed */         \
-    (uint8_t*)p_pic += i_right_margin;                                        \
+    p_pic = (void*)((uint8_t*)p_pic + i_right_margin );                       \
                                                                               \
     /* Increment the Y coordinate in the matrix, modulo 4 */                  \
     i_real_y = (i_real_y + 1) & 0x3;                                          \
@@ -278,7 +278,7 @@ void E_(I420_RGB32)        ( vout_thread_t *, picture_t *, picture_t * );
             /* Height increment: copy previous picture line */                \
             p_vout->p_vlc->pf_memcpy( p_pic, p_pic_start,                     \
                                       p_vout->output.i_width * BPP );         \
-            (uint8_t*)p_pic += p_dest->p->i_pitch;                            \
+            p_pic = (void*)((uint8_t*)p_pic + p_dest->p->i_pitch );           \
         }                                                                     \
         i_scale_count += p_vout->output.i_height;                             \
         break;                                                                \
index 1cac064732c5c6de909375f7d2eaf7019eca58c6..2c2e6207d83f071a1f98cf01364b25ce2308bc48 100644 (file)
@@ -2,7 +2,7 @@
  * i420_yuy2.h : YUV to YUV conversion module for vlc
  *****************************************************************************
  * Copyright (C) 2000, 2001 VideoLAN
- * $Id: i420_yuy2.h,v 1.2 2003/08/29 18:58:05 fenrir Exp $
+ * $Id$
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -132,12 +132,12 @@ movq      %%mm1, (%1)   # Store YUYV                                      \n\
     *(p_line1)++ = *(p_y1)++; *(p_line2)++ = *(p_y2)++;                     \
 
 #define C_YUV420_Y211( )                                                    \
-    *(p_line1)++ = *(p_y1); ((uint16_t*)p_y1)++;                            \
-    *(p_line2)++ = *(p_y2); ((uint16_t*)p_y2)++;                            \
-    *(p_line1)++ = *(p_line2)++ = *(p_u) - 0x80; ((uint16_t*)p_u)++;        \
-    *(p_line1)++ = *(p_y1); ((uint16_t*)p_y1)++;                            \
-    *(p_line2)++ = *(p_y2); ((uint16_t*)p_y2)++;                            \
-    *(p_line1)++ = *(p_line2)++ = *(p_v) - 0x80; ((uint16_t*)p_v)++;        \
+    *(p_line1)++ = *(p_y1); p_y1 += 2;                                      \
+    *(p_line2)++ = *(p_y2); p_y2 += 2;                                      \
+    *(p_line1)++ = *(p_line2)++ = *(p_u) - 0x80; p_u += 2;                  \
+    *(p_line1)++ = *(p_y1); p_y1 += 2;                                      \
+    *(p_line2)++ = *(p_y2); p_y2 += 2;                                      \
+    *(p_line1)++ = *(p_line2)++ = *(p_v) - 0x80; p_v += 2;                  \
 
 #endif
 
index 3e20357924651339d9a199a6a4256ad3e482a0f7..f317fa83badb53ce8dd30536c50827cd4ad8abd4 100644 (file)
@@ -2,7 +2,7 @@
  * i422_yuy2.h : YUV to YUV conversion module for vlc
  *****************************************************************************
  * Copyright (C) 2002 VideoLAN
- * $Id: i422_yuy2.h,v 1.2 2003/08/29 18:58:05 fenrir Exp $
+ * $Id$
  *
  * Authors: Samuel Hocevar <sam@zoy.org>
  *
@@ -83,10 +83,10 @@ movq      %%mm1, 8(%0)  # Store high UYVY                                 \n\
     *(p_line)++ = *(p_y)++;                                                 \
 
 #define C_YUV422_Y211( p_line, p_y, p_u, p_v )                              \
-    *(p_line)++ = *(p_y); ((uint16_t*)p_y)++;                               \
-    *(p_line)++ = *(p_u) - 0x80; ((uint16_t*)p_u)++;                        \
-    *(p_line)++ = *(p_y); ((uint16_t*)p_y)++;                               \
-    *(p_line)++ = *(p_v) - 0x80; ((uint16_t*)p_v)++;                        \
+    *(p_line)++ = *(p_y); p_y += 2;                                         \
+    *(p_line)++ = *(p_u) - 0x80; p_u += 2;                                  \
+    *(p_line)++ = *(p_y); p_y += 2;                                         \
+    *(p_line)++ = *(p_v) - 0x80; p_v += 2;                                  \
 
 #endif