i am using ffmpeg for video merge. as it contains 3-4 steps. in one step in which i wants to extract audio part from multiple videos and get single merged audio. i am facing error:
[avs @ 6c370838 JAVIFileOpen faild with error - 2147221164E:\mypath\bin\debug\videos\video.avs: Error while opening file
i am using below command (using c#) to get audio part: <<<>>>
ffmpeg.exe -i "E:\mypath\bin\Debug\Videos\video.avs" -acodec pcm_s16le -ar 41000 -ab 64k -y -ac 2 "E:\mypath\bin\Debug\Videos\audio.wav"
and the text in video.avs is :
video = UnalignedSplice(DirectShowSource("bumper.wmv", fps = 25, Convertfps = true), DirectShowSource("video.wmv", fps = 25, Convertfps = true, audio = false), DirectShowSource("trailer.wmv", fps = 25, Convertfps =true))
audio = DirectShowSource("video.wmv", video = false)
Clip = AudioDub(video, audio)
DelayAudio(Clip, +1)
I am using below code to write video.avs file:
StreamWriter writer2 = new StreamWriter(Application.StartupPath + "开发者_Go百科\\Videos\\videoPart.avs");
writer2.WriteLine("UnalignedSplice(DirectShowSource(\"" + "bumper.wmv" + "\", fps = 25, Convertfps = true),"
+ " DirectShowSource(\"" + "video.wmv" + "\", fps = 25, Convertfps = true, audio = false),"
+ " DirectShowSource(\"" + "trailer.wmv" + "\", fps = 25, Convertfps =true))");
writer2.Close();
Please help me.
finally i got the answer. i was getting this error because i am using .avs files which cannot be read by ffmpeg. to make ffmpeg to use .avs file we will have to install "Avisynth".
you can download "Avisynth" from : http://www.videohelp.com/tools/Avisynth
精彩评论