I am doing a research of how to split a video in four fragments. I have seen a lot of solutions and libraries. I was looking at this library:
https://github.com/AydinAdn/MediaToolkit
And this is the code for splitting the video
var inputFile = new MediaFile {Filename = @"C:\Path\To_Video.flv"};
var outputFile = new MediaFile {Filename = @"C:\Path\To_Save_ExtractedVideo.flv"};
using (var engine = new Engine())
{
engine.GetMetadata(inputFile);
var options = new ConversionOptions();
// This example will create a 25 second video, starting from the
// 30th second of the original video.
//// First parameter requests the starting frame to cut the media from.
//// Second parameter requests how long to cut the video.
options.CutMedia(TimeSpan.FromSeconds(30), TimeSpan.FromSeconds(25));
engine.Convert(inputFile, outputFile, options);
}
The code is splitting just one fragment. Is there a way to split it in four fragments?
Kind regards
PS: the solution must be in C# and already have seen the Directshow solution.