diff options
author | Clément Bœsch <ubitux@gmail.com> | 2016-01-08 18:16:10 +0300 |
---|---|---|
committer | Vittorio Giovara <vittorio.giovara@gmail.com> | 2016-01-11 23:32:56 +0300 |
commit | e8bc642202c10beda1ea4e93ec8492b1e39805e5 (patch) | |
tree | fa974fb54c3d1b8bfb244f7ac0bce6e95e2ccdd6 /libavutil/imgutils.c | |
parent | 7570c9e04f010c9b3bfdeb4338d330f2cdd25278 (diff) |
lavu: add AV_CEIL_RSHIFT and use it in various places
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Diffstat (limited to 'libavutil/imgutils.c')
-rw-r--r-- | libavutil/imgutils.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavutil/imgutils.c b/libavutil/imgutils.c index 4fb7a9b0aa..6c581396a3 100644 --- a/libavutil/imgutils.c +++ b/libavutil/imgutils.c @@ -291,7 +291,7 @@ void av_image_copy(uint8_t *dst_data[4], int dst_linesizes[4], int h = height; int bwidth = av_image_get_linesize(pix_fmt, width, i); if (i == 1 || i == 2) { - h= -((-height)>>desc->log2_chroma_h); + h = AV_CEIL_RSHIFT(height, desc->log2_chroma_h); } av_image_copy_plane(dst_data[i], dst_linesizes[i], src_data[i], src_linesizes[i], |