From: Good Guy Date: Tue, 23 Jan 2018 03:53:42 +0000 (-0700) Subject: fix ffmpeg w/h setup X-Git-Url: https://git.cinelerra-gg.org/git/?a=commitdiff_plain;h=09a376184b24f90b293d49bfc1b0add80d536a75;p=goodguy%2Fhistory.git fix ffmpeg w/h setup --- 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 ) {