Hello all,
I have different video files.
I want to combine this into single one using ffmpeg.
i am using the following command
ffmpeg -f concat -safe 0 -i inputs.txt -vcodec copy -acodec copy output.mp4
in the inputs.txt i have given the list of the names of the files to be combined
as
file file1.mp4
file file2.mp4
when i run the above command it is giving me a video much greater than the sum of the original video lengths and from second video onwards the audio is muted or corrupted.
can some some one help me in fixing this issue.
Regards
Kamalakar
Try StreamFab Downloader and download from Netflix, Amazon, Youtube! Or Try DVDFab and copy Blu-rays! or rip iTunes movies!
+ Reply to Thread
Results 1 to 6 of 6
Thread
-
-
Can't be done. One audio has to be reencoded to match the sample rate of the other.
-
Actually both the videos are same but i changed the audio of one file with another audio file using another audio file by using ffmpeg command
I have arrived at file1 by replacing the audio of file2 with the audio of new_audio.mp3 file attached.
ffmpeg -i withsound.mp4 -i new_audio.mp3 -map 0:0 -map 1:0 -c:v copy -c:a aac -b:a 256k -shortest OUTPUT1.mp4
so instead of replacing the audio of one video with another audio file can we reencode the audio before replacing the audio of the video so that i can merge both the videos.
can some one help me how to renconde the audio of new_audio.mp3 in ffmpeg -
-ar 44.1k to change the sample rate
Replace audio in file1.mp4 with 44.1Khz version , to produce "file1b.mp4"
Code:ffmpeg -i file1.mp4 -i new_audio.mp3 -map 0:0 -map 1:0 -c:v copy -c:a aac -b:a 256k -ar 44.1k -shortest file1b.mp4
Code:file file1b.mp4 file file2.mp4
-
Dear all,
I am trying to club two types of files. One is in english and another is the translated portion of the english video in telugu.
Telugu video follows the english video
It worked when only one english and telugu files are given are given for concatenation. But when i give english1.mp4,telugu1.mp4 and english2.mp4and telugu.mp4 in this sequence, the video's audio is getting muted when english2 portion of the mp4 is playing. and audio is resumed when telugu2 portion is played
This is happening in VLC while the media player is playing the video properly with out muting any portion of the video. do i need to do any setting changes in VLC so that it plays the audio without muting.
I am using this command to combine four files
ffmpeg -f concat -safe 0 -i inputs.txt -vcodec copy -acodec copy output_851.mp4
the input.txt has the following names
file '1_english.mp4'
file '1_tr.mp4'
file '3_english.mp4'
file '3_tr.mp4'
English MP4 files has the following parameters
Bit Rate = 96kbps
No of Channels = 2 channels
Audi Sample rate= 44khz
the tr mp4 files has the following parameters
Bit Rate = 144kbps
No of Channels = 1 channel(mono)
Audi Sample rate= 44khz
I have replace the english audio with telugu audio by using the following command in ffmpeg in telugu.mp4 file
for %%g in (*mp3) do echo ffmpeg -i %%~ng%inputvideo_prefix%.mp4 -i %%g -map 0:0 -map 1:0 -c:v copy -c:a aac -ar 44.1k -shortest %%~ng%outputvideo_prefix%.mp4
I have uploaded the split_video.mp4 which is a portion of the final video. kindly play it in VLC and Windows media player and see the difference.
Similar Threads
-
How to find single bit errors in otherwise identical video files?
By dgpretzel in forum EditingReplies: 6Last Post: 19th Feb 2018, 13:39 -
How To Rip Blu Ray Movie To Single File? (Movie Is Not Single File)
By ripperz214 in forum Newbie / General discussionsReplies: 0Last Post: 7th Sep 2016, 16:01 -
How to Create 1 Single IDX file from Several Independent SRT Files?
By devilcoelhodog in forum SubtitleReplies: 2Last Post: 29th Jun 2016, 16:42 -
Best method when rendering single frames from a video file.
By e.korpse in forum Newbie / General discussionsReplies: 6Last Post: 19th May 2016, 16:59 -
A single .m4v file to a single DVD-Video disk?
By Hamstor in forum Authoring (DVD)Replies: 7Last Post: 25th Sep 2015, 14:37