[FFmpeg-user] Need Help For Splitting, Re-Encoding and Joining again

Gabriel Balaich roderrooder at gmail.com
Thu Mar 29 20:25:18 EEST 2018


> And for MP4 if we change it to .ts then again we need to convert it to MP4
> i don't think this will fix the issue.


I understand that it seems like an odd thing to do, but I've experienced
the
exact same thing you are, and using the .ts container during segmentation
got rid of all audio jumps.

Can't hurt to try, if you don't need the .mp4 container in the end result I
would just go with .ts for the whole process.

1) ffmpeg -i F:\video_data_set\4k_compressed.mp4 -f segment
-segment_time 5 -segment_start_number 1 -codec copy
F:\video_data_set\test\%d_4k_compressed.ts

2) ffmpeg -hide_banner -i F:\video_data_set\test\1_4k_compressed.mp4
-c:a aac -ar 44100 -b:a 128k -c:v libx264 -x264opts nal-hrd=cbr:force-cfr=1
-pix_fmt yuv420p -profile:v baseline -level 3.0 -vf
"scale=1280:-2,setdar=16:9" -b:v 3.9M -minrate 3.9M -maxrate 3.9M -bufsize
7.8M -preset ultrafast -crf 18 -r 30 -g 30 -threads 8 -copyts
F:\video_data_set\test\1_4k_compressed_1.ts

3) ffmpeg -hide_banner -f concat -safe 0 -i
F:\video_data_set\test\files_2.txt
-c copy -threads 8 F:\video_data_set\4k_compressed_1.ts


More information about the ffmpeg-user mailing list