Skip to main content

Execute FFMPEG Commands

ASP.NET Media Handler Pro support executing your own custom ffmpeg command directly for various video and audio operations in your asp.net, c# and vb.net applications.

For latest codes and discussion please visit media handler pro discussion forum section

C# Sample Code

The following example will use custom ffmpeg command for grabbing multiple thumbs from video using execute_ffmpeg() method of media handler pro.

MediaHandler _mhandler = new MediaHandler();
_mhandler.FFMPEGPath = HttpContext.Current.Server.MapPath("~\\ffmpeg\\ffmpeg.exe");
_mhandler.CustomCommand = "-i c:\\video\\sample.avi -an -y -f image2 -vframes 20 c:\\video\\sample%d.jpg";
_mhandler.Execute_FFMPEG();   

Using this function you can also process any type of ffmpeg commands.