![]() For it to work you must have your original and converted files on separate directories, each with the same number of files (the directories must only have the video files, as other files/directories will interfere) and in the same order. ![]() I made a bash script that can batch transfer the metadata, using touch as suggested above. Read the x264 encoding guide on the FFmpeg wiki for more. See the AAC encoding guide for more info. 23 is default, and anything below 18 will probably be visually lossless. In order to change the quality of the output, you can: This will convert the input with the x264 encoder and AAC audio to an output file, copying the original metadata. In the simplest case you can do your conversion like this: ffmpeg -i in.mp4 -c:v libx264 -crf 23 -c:a aac -map_metadata 0 out.mp4 $ mediainfo fixed.mp4 | grep "Encoded date" | head -n 1Īctually, you don't really need to use Handbrake if you can use FFmpeg, which Handbrake relies on anyway. Here's the final file after mapping the metadata: $ ffmpeg -i in.mp4 -i out.mp4 -map 1 -map_metadata 0 -c copy fixed.mp4 ![]() Here's the file after Handbrake conversion: $ mediainfo out.mp4 | grep "Encoded date" | head -n 1
0 Comments
Leave a Reply. |