From 09a376184b24f90b293d49bfc1b0add80d536a75 Mon Sep 17 00:00:00 2001 From: Good Guy Date: Mon, 22 Jan 2018 20:53:42 -0700 Subject: [PATCH] fix ffmpeg w/h setup --- cinelerra-5.1/cinelerra/ffmpeg.C | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cinelerra-5.1/cinelerra/ffmpeg.C b/cinelerra-5.1/cinelerra/ffmpeg.C index 9f87bc18..167ee479 100644 --- a/cinelerra-5.1/cinelerra/ffmpeg.C +++ b/cinelerra-5.1/cinelerra/ffmpeg.C @@ -2085,9 +2085,9 @@ int FFMPEG::open_encoder(const char *type, const char *spec) ctx->pix_fmt = pix_fmt; const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(pix_fmt); int mask_w = (1<log2_chroma_w)-1; - if( mask_w > 0 ) ctx->width = (vid->width+mask_w) & ~mask_w; + ctx->width = (vid->width+mask_w) & ~mask_w; int mask_h = (1<log2_chroma_h)-1; - if( mask_h > 0 ) ctx->height = (vid->height+mask_h) & ~mask_h; + ctx->height = (vid->height+mask_h) & ~mask_h; ctx->sample_aspect_ratio = to_sample_aspect_ratio(asset); AVRational frame_rate = check_frame_rate(codec, vid->frame_rate); if( !frame_rate.num || !frame_rate.den ) { -- 2.26.2