Page 1 of 1

Getting video frames Bitmaps...

Posted: 30 Jul 2019 17:33
by macropolo
Dear All, how could be possible to get an event (with a callback method or whatever) to get each new frame feeded to the VLC Player?

My intention is to make some video processing over the video stream, so I have to gain access to each new frame as a Bitmap or Canvas object. A syncrhonous event and the data itself of the frame buffer would be necessary for this.

Ususally I work with Delphi but any C++, Java or whatever example would be quite enough.

Many thanks in advance.

Re: Getting video frames Bitmaps...

Posted: 31 Jul 2019 04:23
by mfkl
Hi macropolo,

Here's a C# example on how to do this: https://github.com/ZeBobo5/Vlc.DotNet/blob/develop/src/Vlc.DotNet.Wpf/VlcVideoSourceProvider.cs

Re: Getting video frames Bitmaps...

Posted: 31 Jul 2019 13:44
by macropolo
Many thanks mfkl.

I'm going to take a look to it. As far as I understand from my first scan, the deal is with two callback events:

LockVideo(IntPtr userdata, IntPtr planes)

DisplayVideo(IntPtr userdata, IntPtr picture)

I will explore the use of these methods to get the corresponding image.

Thanks.