diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2006-08-19 20:55:02 +0000 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2006-08-19 20:55:02 +0000 |
commit | 67eca72dc0183025397191dbf93e1e5033354afb (patch) | |
tree | 471fa3979b7cb93c6aad6783d0701e79972a8da5 /libavcodec/mpegvideo.c | |
parent | 0eb6817d9821bf67f33ccfe9b427cf736b95881e (diff) | |
download | ffmpeg-67eca72dc0183025397191dbf93e1e5033354afb.tar.gz |
SWAP
Originally committed as revision 6030 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/mpegvideo.c')
-rw-r--r-- | libavcodec/mpegvideo.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/libavcodec/mpegvideo.c b/libavcodec/mpegvideo.c index a6c93c47a8..c7a76597a7 100644 --- a/libavcodec/mpegvideo.c +++ b/libavcodec/mpegvideo.c @@ -1687,7 +1687,7 @@ void MPV_frame_end(MpegEncContext *s) * @param color color of the arrow */ static void draw_line(uint8_t *buf, int sx, int sy, int ex, int ey, int w, int h, int stride, int color){ - int t, x, y, fr, f; + int x, y, fr, f; sx= clip(sx, 0, w-1); sy= clip(sy, 0, h-1); @@ -1698,8 +1698,8 @@ static void draw_line(uint8_t *buf, int sx, int sy, int ex, int ey, int w, int h if(ABS(ex - sx) > ABS(ey - sy)){ if(sx > ex){ - t=sx; sx=ex; ex=t; - t=sy; sy=ey; ey=t; + SWAP(int, sx, ex); + SWAP(int, sy, ey); } buf+= sx + sy*stride; ex-= sx; @@ -1712,8 +1712,8 @@ static void draw_line(uint8_t *buf, int sx, int sy, int ex, int ey, int w, int h } }else{ if(sy > ey){ - t=sx; sx=ex; ex=t; - t=sy; sy=ey; ey=t; + SWAP(int, sx, ex); + SWAP(int, sy, ey); } buf+= sx + sy*stride; ey-= sy; |