unosquare / ffmediaelement

FFME: The Advanced WPF MediaElement (based on FFmpeg)
https://unosquare.github.io/ffmediaelement/
Other
1.17k stars 238 forks source link

[Question] How to get screencaps? #569

Closed hutterm closed 3 years ago

hutterm commented 3 years ago

Is there a way to get screencaps from a video with this library?

I want to implement some kind of preview onto a time slider when hovering with the mouse. Is there a convenient way to use this library for that or do I have to resort to external ways?

Issue Categories

MattE303 commented 3 years ago

the ability to obtain a keyframe image for a specified timecode/position would be useful to me as well.

hutterm commented 3 years ago

the way I solved it for now is to open the file in a secondary MediaElement as well and then use Seek and CaptureBitmapAsync but this feels quite hackish

mariodivece commented 3 years ago

the CaptureBitmapAsync method works. If you'd need a more precise and complex alternative, subscribe to the RenderingVideo event of the control.