Convert Images to Video

Media Handler Pro 5.0 or later support converting sequence of images to video format.

Requirements:

  • Images must be in sequence e.g sample_001.jpg, sample_002.jpg ...
  • Images must be in .jpg format.

See sample code for publishing thumbs to video file below.

Media Handler Pro ver 5.0 Documentation !

Sample Code thumbs to video conversion. (C# only)

Note: It requires Media Handler Pro 5.0 or later

Parameter Settings

MediaHandler _mhandler = new MediaHandler();

string RootPath = Server.MapPath(Request.ApplicationPath);
_mhandler.FFMPEGPath = HttpContext.Current.Server.MapPath("~\\ffmpeg\\ffmpeg.exe");
_mhandler.InputPath = RootPath + "\\contents\\source";
_mhandler.OutputPath = RootPath + "\\contents\\output";

_mhandler.FileName = "sample_"; // represent sample_001.jpg, sample_002.jpg etc.
_mhandler.OutputFileName = "sample";
_mhandler.OutputExtension = ".flv";

// Call method to process parameters

VideoInfo info = _mhandler.ImagesToVideo();
if (info.ErrorCode > 0)
{
Response.Write("Error occured: Error Code: " + info.ErrorCode + "<br />Error Message: " + info.ErrorMessage);
return;
}