X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=libavfilter%2Fvf_aspect.c;h=f0467b5247fbf23ce7268616e55aed3188ccb3e9;hb=4be1714b12b6c311a99a64888ea5f279c3ed9885;hp=c042698ef7acc5cd3d7f72a2b38f2219e622431f;hpb=b14761d1f8372dfe558193b8b754b9f1a858077d;p=ffmpeg diff --git a/libavfilter/vf_aspect.c b/libavfilter/vf_aspect.c index c042698ef7a..f0467b5247f 100644 --- a/libavfilter/vf_aspect.c +++ b/libavfilter/vf_aspect.c @@ -78,7 +78,7 @@ static int filter_frame(AVFilterLink *link, AVFrame *frame) static inline void compute_dar(AVRational *dar, AVRational sar, int w, int h) { if (sar.num && sar.den) { - av_reduce(&dar->num, &dar->den, sar.num * w, sar.den * h, INT_MAX); + av_reduce(&dar->num, &dar->den, sar.num * (int64_t)w, sar.den * (int64_t)h, INT_MAX); } else { av_reduce(&dar->num, &dar->den, w, h, INT_MAX); } @@ -185,7 +185,7 @@ static const AVFilterPad avfilter_vf_setdar_outputs[] = { { NULL } }; -AVFilter ff_vf_setdar = { +const AVFilter ff_vf_setdar = { .name = "setdar", .description = NULL_IF_CONFIG_SMALL("Set the frame display aspect ratio."), .priv_size = sizeof(AspectContext), @@ -249,7 +249,7 @@ static const AVFilterPad avfilter_vf_setsar_outputs[] = { { NULL } }; -AVFilter ff_vf_setsar = { +const AVFilter ff_vf_setsar = { .name = "setsar", .description = NULL_IF_CONFIG_SMALL("Set the pixel sample aspect ratio."), .priv_size = sizeof(AspectContext),