Home > Blogs > Tags > Jpg To Video Blog Posts
Posted on July 9, 2010 0:40 AM by Moderator. Tags: asp.net video , extract frames , jpg to video
You can use the following code through ASP.NET Media Handler Pro
component to extract all frames of video into jpg images.
Extracting Frames:

_mhandler.InputPath = RootPath + "\\contents\\original";
_mhandler.OutputPath = RootPath + "\\contents\\thumbs";
_mhandler.FileName = "xmen-origins-wolverine.mp4";
_mhandler.OutputFileName = "sample_";
_mhandler.OutputExtension = "%010d.jpg";
_mhandler.Force = "image2";
VideoInfo info = _mhandler.Process();

Re Encoding Frames / Images into Video:
Example below will encode all jpg frames into flash flv video, you can
encode it in any format.

_mhandler.InputPath = RootPath + "\\contents\\thumbs";
_mhandler.OutputPath = RootPath + "\\contents\\flv";
_mhandler.FileName = "sample_.%010d.jpg";
_mhandler.OutputFileName = "sample_img_vid";
_mhandler.OutputExtension = "flv";
_mhandler.Force = "flv";
// _mhandler.MaxQuality = true;
_mhandler.Audio_Bitrate = 32;
_mhandler.Audio_SamplingRate = 22050;
VideoInfo info = _mhandler.Process();

If you receive Error Code 101, you can request updated MHP through our
support email.
complete story
Posted in Media Handler Pro ,
© 2007 - 2012, mediasoftpro.com  | Site Map | Privacy Policy | Terms of Use