FFMpegCore icon indicating copy to clipboard operation
FFMpegCore copied to clipboard

About Extracting Image From Video

Open kbrmumcu opened this issue 1 year ago • 2 comments

I am using the code below. It gives me the entire frame of the image. I want it to continuously render images until the video ends at a certain second of the video. How can I do this?

FFMpegArguments.FromFileInput(videofilePath).OutputToFile("tmp/Video/Frame%05d.png", true, Options => { Options.WithVideoCodec(VideoCodec.Png); }).ProcessSynchronously();

kbrmumcu avatar Mar 26 '25 07:03 kbrmumcu

int fps=1; FFMpegArguments.FromFileInput(filePath).OutputToFile("tmp/Video/Frame%09d.png", true, Options => { Options.WithVideoCodec(VideoCodec.Png); Options.WithGifPaletteArgument(0, new Size(100,100), fps); }).ProcessSynchronously();

I solved the FPS as 1 but I can't change it because it is int when I want less than 1 second. How can I create an example of "-vf fps=0.5" ?

kbrmumcu avatar Mar 26 '25 08:03 kbrmumcu

Maybe you're looking for this? https://github.com/withsalt/WithSalt.FFmpeg.Recorder

withsalt avatar Mar 27 '25 14:03 withsalt