diff options
author | Ganesh Ajjanagadde <gajjanagadde@gmail.com> | 2015-11-25 17:27:27 -0500 |
---|---|---|
committer | Ganesh Ajjanagadde <gajjanagadde@gmail.com> | 2015-12-02 18:31:56 -0500 |
commit | fa5d299496c15e992240914ae05b92d9b74eb3c4 (patch) | |
tree | 8c86973a60ad58bfd616d3bdab15350eb84ebb31 | |
parent | 1bb7db217d9000a8e5fe53d9df691884fe8014bf (diff) | |
download | ffmpeg-fa5d299496c15e992240914ae05b92d9b74eb3c4.tar.gz |
avfilter/vsrc_mptestsrc: use lrint instead of floor hack
lrint is faster, and is more consistent across the codebase.
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Ganesh Ajjanagadde <gajjanagadde@gmail.com>
-rw-r--r-- | libavfilter/vsrc_mptestsrc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/vsrc_mptestsrc.c b/libavfilter/vsrc_mptestsrc.c index 668a001f97..1cdd3a4370 100644 --- a/libavfilter/vsrc_mptestsrc.c +++ b/libavfilter/vsrc_mptestsrc.c @@ -121,7 +121,7 @@ static void idct(uint8_t *dst, int dst_linesize, int src[64]) for (k = 0; k < 8; k++) sum += c[k*8+i]*tmp[8*k+j]; - dst[dst_linesize*i + j] = av_clip_uint8((int)floor(sum+0.5)); + dst[dst_linesize*i + j] = av_clip_uint8(lrint(sum)); } } } |