summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/rmd_yuv_utils.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/rmd_yuv_utils.c b/src/rmd_yuv_utils.c
index 6570945..1a449f6 100644
--- a/src/rmd_yuv_utils.c
+++ b/src/rmd_yuv_utils.c
@@ -226,8 +226,8 @@ static inline int blocknum(int xv, int yv, int widthv, int blocksize)
yuv_V++; \
} \
\
- yuv_U += ((yuv)->uv_stride - ((width_tm - w_odd * 2) >> 1)); \
- yuv_V += ((yuv)->uv_stride - ((width_tm - w_odd * 2) >> 1)); \
+ yuv_U += ((yuv)->uv_stride - ((width_tm - w_odd) >> 1)); \
+ yuv_V += ((yuv)->uv_stride - ((width_tm - w_odd) >> 1)); \
\
datapi += width_tm + w_odd; \
if (sampling == __PXL_AVERAGE) \
@@ -324,8 +324,8 @@ static inline int blocknum(int xv, int yv, int widthv, int blocksize)
yuv_V++; \
} \
\
- yuv_U += ((yuv)->uv_stride - ((width_tm - w_odd * 2) >> 1)); \
- yuv_V += ((yuv)->uv_stride - ((width_tm - w_odd * 2) >> 1)); \
+ yuv_U += ((yuv)->uv_stride - ((width_tm - w_odd) >> 1)); \
+ yuv_V += ((yuv)->uv_stride - ((width_tm - w_odd) >> 1)); \
\
datapi += width_tm + w_odd; \
datapi_back += width_tm + w_odd; \
@@ -356,8 +356,8 @@ static inline int blocknum(int xv, int yv, int widthv, int blocksize)
yuv_V++; \
} \
\
- yuv_U += ((yuv)->y_stride - (width_tm - w_odd * 2)) >> 1; \
- yuv_V += ((yuv)->y_stride - (width_tm - w_odd * 2)) >> 1; \
+ yuv_U += ((yuv)->uv_stride - ((width_tm - w_odd) >> 1)); \
+ yuv_V += ((yuv)->uv_stride - ((width_tm - w_odd) >> 1)); \
\
datapi += width_tm + w_odd; \
datapi_back += width_tm + w_odd; \
© All Rights Reserved