string videoname = name of video uploaded on site in folder Videos without extenstion; string videoext = extension of video //or example .mpg) // convert video to mpg format string inputfile = Page.MapPath("Videos\\"+videoname+videoext); string outputfile = Page.MapPath("") + "\\VideoMpg\\"+ videoname +".mpg";//VideoMpg is the folder in which the converted video is to be stored string fileargs = "-i " + inputfile + " -ar 22050 " + outputfile; Process proc = new Process(); proc.StartInfo.FileName = Page.MapPath("ffmpeg\\ffmpeg.exe"); proc.StartInfo.Arguments = fileargs; proc.StartInfo.UseShellExecute = false; proc.StartInfo.CreateNoWindow = false; proc.StartInfo.RedirectStandardInput = false; try { proc.Start(); } catch (Exception ex) { Response.Write(ex.Message); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)