Use av_clip_uint8 instead of equivalent but unoptimzed code,
Originally committed as revision 18985 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
6f62e2c72d
commit
abeee5ccb8
@ -81,11 +81,7 @@ static inline unsigned char fix (int pix14)
|
|||||||
int tmp;
|
int tmp;
|
||||||
|
|
||||||
tmp = (pix14 + 0x80000) >> 20;
|
tmp = (pix14 + 0x80000) >> 20;
|
||||||
if (tmp < 0)
|
return av_clip_uint8(tmp);
|
||||||
return 0;
|
|
||||||
if (tmp > 255)
|
|
||||||
return 255;
|
|
||||||
return tmp;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user