diff options
author | Zuxy Meng <zuxy.meng@gmail.com> | 2010-01-15 08:51:51 +0000 |
---|---|---|
committer | Zuxy Meng <zuxy.meng@gmail.com> | 2010-01-15 08:51:51 +0000 |
commit | a959e24780e4570061df034ddf0271992f3e6dc6 (patch) | |
tree | f982ad3bd25f48e65c8f31d92b4251a29c599ef8 /libswscale/yuv2rgb.c | |
parent | 7c2de274e7ae6743cbd3f3f8b1aeebdf353cfdf5 (diff) | |
download | ffmpeg-a959e24780e4570061df034ddf0271992f3e6dc6.tar.gz |
Const correctness for src pointer. Remove all constness related warnings in
libswscale.
Originally committed as revision 30306 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale
Diffstat (limited to 'libswscale/yuv2rgb.c')
-rw-r--r-- | libswscale/yuv2rgb.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libswscale/yuv2rgb.c b/libswscale/yuv2rgb.c index 2d53a5f4e6..5e20dc843a 100644 --- a/libswscale/yuv2rgb.c +++ b/libswscale/yuv2rgb.c @@ -91,7 +91,7 @@ const int32_t ff_yuv2rgb_coeffs[8][4] = { dst[12*i+10] = dst[12*i+11] = b[Y]; #define YUV2RGBFUNC(func_name, dst_type, alpha) \ -static int func_name(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY, \ +static int func_name(SwsContext *c, const uint8_t* src[], int srcStride[], int srcSliceY, \ int srcSliceH, uint8_t* dst[], int dstStride[]) \ {\ int y;\ @@ -105,11 +105,11 @@ static int func_name(SwsContext *c, uint8_t* src[], int srcStride[], int srcSlic dst_type *dst_2 = (dst_type*)(dst[0] + (y+srcSliceY+1)*dstStride[0]);\ dst_type av_unused *r, *b;\ dst_type *g;\ - uint8_t *py_1 = src[0] + y*srcStride[0];\ - uint8_t *py_2 = py_1 + srcStride[0];\ - uint8_t *pu = src[1] + (y>>1)*srcStride[1];\ - uint8_t *pv = src[2] + (y>>1)*srcStride[2];\ - uint8_t av_unused *pa_1, *pa_2;\ + const uint8_t *py_1 = src[0] + y*srcStride[0];\ + const uint8_t *py_2 = py_1 + srcStride[0];\ + const uint8_t *pu = src[1] + (y>>1)*srcStride[1];\ + const uint8_t *pv = src[2] + (y>>1)*srcStride[2];\ + const uint8_t av_unused *pa_1, *pa_2;\ unsigned int h_size = c->dstW>>3;\ if (alpha) {\ pa_1 = src[3] + y*srcStride[3];\ |