Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.


Go Back   Doom9's Forum > Video Encoding > MPEG-2 Encoding

Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
Old 9th October 2020, 08:23   #1  |  Link
Registered User
Join Date: Jan 2013
Posts: 50
ffmpeg CLI syntax for encoding DVD Remux please


Source NTSC DVD Remux - specs: ( Mediainfo = https://pastebin.com/dRTLVWFC )
1) It has 720 x 480 resolution.
2) PAR should be 40/33 - tried to pass "--sar 40:33" to x264
3) cropping should be Crop(2,50,-0,-42) so used filter:v "crop=718:390:2:50"
4) De-interlacing needs to be done so used -vf yadif as one of 5 frames is duplicate.

so tried - (to encode first 10 min)
Z:\>ffmpeg -y -i "ABCD_Source.mkv" -ss 0 -t 600 -filter:v "crop=718:390:2:50" -vf yadif -vcodec libx264 -preset placebo -crf 16 -refs 16 -sar "40:33" -x264-params  "me=umh:subme=11:bframes=16:deblock=-3,-3:no-dct-decimate=1:rc-lookahead=100:me_range=48:keyint_min=23" -acodec copy  ABCD_ffm2.mkv
But it throws the below error:
[matroska @ 00000199d16f1e80] Aspect ratio mismatch between muxer (186/157) and encoder layer (40/33)
Could not write header for output file #0 (incorrect codec parameters ?): Invalid argument
Error initializing output stream 0:0 --
Conversion failed!
Then I tried without "-sar 40:33" , it encodes but with wrong o/p resolution 720:480. Expected is 718x390 with display size 870x390 as 718*(40/33)=870.30.

Please advise correct ffmpeg command with deinterlacing, cropping and SAR/PAR/DAR parameter for a DVD remux source. It would be good to include Color matrix

bjoker is offline   Reply With Quote

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

All times are GMT +1. The time now is 06:07.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2021, vBulletin Solutions Inc.