From 3d6a73e3e545d5468af34704d600a04c99074382 Mon Sep 17 00:00:00 2001 From: diego Date: Sun, 4 Nov 2007 13:41:07 +0000 Subject: [PATCH] Fix previous incorrect commit, +/- has higher precedence than shifts. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@24966 b3059339-0415-0410-9bf9-f77b7e298cf2 --- libvo/vo_directfb2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/libvo/vo_directfb2.c b/libvo/vo_directfb2.c index 45ce526480..df47b3b313 100644 --- a/libvo/vo_directfb2.c +++ b/libvo/vo_directfb2.c @@ -1186,8 +1186,8 @@ static uint32_t get_image(mp_image_t *mpi) if (!frame) { if(mpi->flags&MP_IMGFLAG_PLANAR){ mpi->planes[0]= dst + yoffset * pitch + xoffset; - mpi->planes[1]+= ((yoffset * pitch) >> 2) + (xoffset >> 1); - mpi->planes[2]+= ((yoffset * pitch) >> 2) + (xoffset >> 1); + mpi->planes[1]+= (yoffset * pitch) >> (2 + xoffset) >> 1; + mpi->planes[2]+= (yoffset * pitch) >> (2 + xoffset) >> 1; } else { mpi->planes[0]=dst + yoffset * pitch + xoffset * (mpi->bpp >> 3); }