string inputpath = strFileNamePath;
string outputpath = "C:\\Image\\";
//for (int iIndex = 0; iIndex < 1000; iIndex++)
//{
//string fileargs = "-i" + " " + inputpath + " -ab 56 -ar 44100 -b 200 -r 15 -s 320x240 -f flv " + outputpath + "SRT.flv";
string fileargs = "-i" + " " + inputpath + " " + outputpath + "image.jpg";
System.Diagnostics.Process p = new System.Diagnostics.Process();
p.StartInfo.FileName = "C:\\Documents and Settings\\Badr\\My Documents\\Visual Studio 2008\\Projects\\Video2image2video.\\ffmpeg\\ffmpeg.exe";
p.StartInfo.Arguments = fileargs;
p.StartInfo.UseShellExecute = false;
p.StartInfo.CreateNoWindow = true;
p.StartInfo.RedirectStandardOutput = true;
p.Start();
我有這樣的代碼這個創建僅1視頻的圖像我申請一個循環,但我反覆生成初始圖像我怎麼可以得到所有的視頻如何將視頻轉換爲在c#中使用ffmpeg的圖像文件?
感謝名單的圖片提前
請儘量避免硬編碼路徑,C:\\文件等是令人震驚。使用System.IO.Path.GetDirectoryName(_ System.Reflection.Assembly.GetExecutingAssembly()。GetName()。CodeBase)'要獲取exe所在的路徑 – RvdK 2010-05-18 13:51:20