[x264-devel] commit: remove void* arithmetic from r821 (Loren Merritt )

git version control git at videolan.org
Sun Apr 27 11:16:38 CEST 2008


x264 | branch: master | Loren Merritt <pengvado at akuvian.org> | Tue Apr 22 04:00:24 2008 -0600| [971301a7a1c164620b3e80bcd1e2517d053213c5]

remove void* arithmetic from r821

> http://git.videolan.org/gitweb.cgi/x264.git/?a=commit;h=971301a7a1c164620b3e80bcd1e2517d053213c5
---

 common/frame.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/common/frame.c b/common/frame.c
index a4c33f0..2f1d303 100644
--- a/common/frame.c
+++ b/common/frame.c
@@ -62,13 +62,13 @@ x264_frame_t *x264_frame_new( x264_t *h )
     for( i = 1; i < 3; i++ )
     {
         CHECKED_MALLOC( frame->buffer[i], luma_plane_size/4 );
-        frame->plane[i] = frame->buffer[i] + (frame->i_stride[i] * i_padv + PADH)/2;
+        frame->plane[i] = (uint8_t*)frame->buffer[i] + (frame->i_stride[i] * i_padv + PADH)/2;
     }
     /* all 4 luma planes allocated together, since the cacheline split code
      * requires them to be in-phase wrt cacheline alignment. */
     CHECKED_MALLOC( frame->buffer[0], 4*luma_plane_size);
     for( i = 0; i < 4; i++ )
-        frame->filtered[i] = frame->buffer[0] + i*luma_plane_size + frame->i_stride[0] * i_padv + PADH;
+        frame->filtered[i] = (uint8_t*)frame->buffer[0] + i*luma_plane_size + frame->i_stride[0] * i_padv + PADH;
     frame->plane[0] = frame->filtered[0];
 
     if( h->frames.b_have_lowres )



More information about the x264-devel mailing list