Hello,
since Handbrake will crash randomly i try to convert my videos with ffmpeg. I tried to convert my Handbrake Preset to ffmpeg. With a little help from google it looks like this:
So when i try this my terminal output looks like:Code:ffmpeg -hide_banner \ -i "test.mkv" \ -map_metadata 0 \ -map_chapters 0 \ -metadata title="TITLE" \ -map 0:0 -metadata:s:v:0 language=eng \ -map 0:1 -metadata:s:a:0 language=eng -metadata:s:a:0 \ -map 0:2 -metadata:s:s:0 language=eng -metadata:s:s:0 \ -c:v libx265 -preset slow -x265-params \ crf=21:wpp:ctu=64:min-cu-size=8:max-tu-size=32:tu-intra-depth=1:tu-inter-depth=1:me=1:subme=2:merange=57:no-rect:no-amp:max-merge=2:temporal-mvp:no-early-skip:rdpenalty=0:no-tskip:no-tskip-fast:strong-intra-smoothing:no-lossless:no-cu-lossless:no-constrained-intra:no-fast-intra:open-gop:no-temporal-layers:interlace=0:keyint=240:min-keyint=24:scenecut=40:rc-lookahead=20:lookahead-slices=6:bframes=4:bframe-bias=0:b-adapt=2:ref=3:limit-refs=3:no-limit-modes:weightp:no-weightb:aq-mode=1:qg-size=32:cbqpoffs=0:crqpoffs=0:rd=3:rdoq-level=0:signhide:deblock:sao:no-sao-non-deblock:b-pyramid:cutree:no-intra-refresh:qpstep=4 \ -c:a copy \ -c:s copy \ "OUTPUT.mkv"
I tried to delete the line "map 0:2....." then the error is:Code:[NULL @ 0x556737178dc0] Unable to find a suitable output format for '0:2' 0:2: Invalid argument
Im using Manjaro Linux and ffmpeg 4.2.2. I just want to convert some videos. Perfectly with a script that will convert all files in the folder where i run the script.Code:Missing argument for option 'metadata:s:a:0'. Error splitting the argument list: Invalid argument ffmpeg: Line 9: -c:v: command not fount.
Can somebody help me pls?
If it is usefull here is my Handbrake preset:
Code:{ "PresetList": [ { "AlignAVStart": false, "AudioCopyMask": [ "copy:mp3", "copy:aac", "copy:ac3", "copy:dts", "copy:dtshd" ], "AudioEncoderFallback": "ac3", "AudioLanguageList": [ "und" ], "AudioList": [ { "AudioBitrate": 192, "AudioCompressionLevel": -1.0, "AudioDitherMethod": "auto", "AudioEncoder": "copy:ac3", "AudioMixdown": "5point1", "AudioNormalizeMixLevel": false, "AudioSamplerate": "auto", "AudioTrackDRCSlider": 0.0, "AudioTrackGainSlider": -20.0, "AudioTrackQuality": 0.0, "AudioTrackQualityEnable": false } ], "AudioSecondaryEncoderMode": true, "AudioTrackSelectionBehavior": "first", "ChapterMarkers": true, "ChildrenArray": [], "Default": false, "FileFormat": "av_mkv", "Folder": false, "FolderOpen": false, "InlineParameterSets": false, "Mp4HttpOptimize": false, "Mp4iPodCompatible": false, "PictureAutoCrop": true, "PictureBottomCrop": 0, "PictureCombDetectCustom": "", "PictureCombDetectPreset": "off", "PictureDARWidth": 0, "PictureDeblock": 0, "PictureDeblockCustom": "qp=0:mode=2", "PictureDeinterlaceCustom": "", "PictureDeinterlaceFilter": "off", "PictureDeinterlacePreset": "", "PictureDenoiseCustom": "", "PictureDenoiseFilter": "off", "PictureDenoisePreset": "", "PictureDenoiseTune": "none", "PictureDetelecine": "off", "PictureDetelecineCustom": "", "PictureForceHeight": 0, "PictureForceWidth": 0, "PictureHeight": 720, "PictureItuPAR": false, "PictureKeepRatio": true, "PictureLeftCrop": 0, "PictureLooseCrop": false, "PictureModulus": 2, "PicturePAR": "loose", "PicturePARHeight": 1, "PicturePARWidth": 1, "PictureRightCrop": 0, "PictureRotate": "disable=1", "PictureSharpenCustom": "", "PictureSharpenFilter": "off", "PictureSharpenPreset": "medium", "PictureSharpenTune": "none", "PictureTopCrop": 0, "PictureWidth": 1280, "PresetDescription": "HandBrake's normal, default settings.", "PresetName": "x265fun_ac3720p", "SubtitleAddCC": false, "SubtitleAddForeignAudioSearch": false, "SubtitleAddForeignAudioSubtitle": false, "SubtitleBurnBDSub": false, "SubtitleBurnBehavior": "none", "SubtitleBurnDVDSub": false, "SubtitleLanguageList": [ "deu" ], "SubtitleTrackSelectionBehavior": "all", "Type": 1, "UsesPictureFilters": true, "UsesPictureSettings": 1, "VideoAvgBitrate": 2500, "VideoColorMatrixCode": 0, "VideoEncoder": "x265", "VideoFramerate": "auto", "VideoFramerateMode": "vfr", "VideoGrayScale": false, "VideoLevel": "", "VideoOptionExtra": "wpp:ctu=64:min-cu-size=8:max-tu-size=32:tu-intra-depth=1:tu-inter-depth=1:me=1:subme=2:merange=57:no-rect:no-amp:max-merge=2:temporal-mvp:no-early-skip:rdpenalty=0:no-tskip:no-tskip-fast:strong-intra-smoothing:no-lossless:no-cu-lossless:no-constrained-intra:no-fast-intra:open-gop:no-temporal-layers:interlace=0:keyint=240:min-keyint=24:scenecut=40:rc-lookahead=20:lookahead-slices=6:bframes=4:bframe-bias=0:b-adapt=2:ref=3:limit-refs=3:no-limit-modes:weightp:no-weightb:aq-mode=1:qg-size=32:cbqpoffs=0:crqpoffs=0:rd=3:rdoq-level=0:signhide:deblock:sao:no-sao-non-deblock:b-pyramid:cutree:no-intra-refresh:qpstep=4", "VideoPreset": "slow", "VideoProfile": "main", "VideoQSVAsyncDepth": 4, "VideoQSVDecode": false, "VideoQualitySlider": 21.0, "VideoQualityType": 2, "VideoScaler": "swscale", "VideoTune": "", "VideoTurboTwoPass": false, "VideoTwoPass": false, "x264Option": "", "x264UseAdvancedOptions": false } ], "VersionMajor": 32, "VersionMicro": 0, "VersionMinor": 0 }
odin89
+ Reply to Thread
Results 1 to 6 of 6
-
-
Well I tried with ffmpeg without any troubles:
[Attachment 52563 - Click to enlarge]
[Attachment 52564 - Click to enlarge] -
Why is there an extra "-metadata:s:a:0" and "-metadata:s:s:0" at the end of the map audio and sub lines? The command appears to work properly without those.
-
Be sure you didn't also remove the \ at the end the previous line. The \ means the command is continued on the next line. If you remove the \ the command line interpreter will assume the next line is a new command, not a continuation of the previous. This code works for me in Windows:
Code:ffmpeg -y -hide_banner ^ -i "test.mkv" ^ -map_metadata 0 ^ -map_chapters 0 ^ -metadata title="TITLE" ^ -map 0:0 -metadata:s:v:0 language=eng ^ -map 0:1 -metadata:s:a:0 language=eng ^ -map 0:2 -metadata:s:s:0 language=eng ^ -c:v copy ^ -c:a copy ^ -c:s copy ^ "OUTPUT.mkv"
-
I don't pretend to be anything of an expert, but could that error message be related to the presence or absence of subtitles in the source video?
From the ffmpeg trac:
A trailing ?, such as -map 1:a?, will allow the map to be optional. If the map matches no streams the map will be ignored instead of failing. Note the mapping will still fail if an invalid input_file_index is used; such as if the map refers to an input that does not exist.
https://trac.ffmpeg.org/wiki/Map
Similar Threads
-
Handbrake settings
By BlurayHD in forum Newbie / General discussionsReplies: 2Last Post: 28th Mar 2020, 22:29 -
Handbrake DVD Best Settings
By Anonymous64 in forum DVD RippingReplies: 5Last Post: 28th Apr 2017, 14:37 -
BEST Handbrake settings?
By alvis111 in forum Newbie / General discussionsReplies: 4Last Post: 12th Jan 2017, 20:06 -
Handbrake picture settings, please take a look.
By botdvd in forum Blu-ray RippingReplies: 1Last Post: 26th May 2016, 03:13 -
Some Handbrake Settings Confusing.
By DWreck1995 in forum Video ConversionReplies: 4Last Post: 5th Sep 2015, 23:23