Overlaying my own graphics on the SDL window when VLC is playing

This forum is about all development around libVLC.
Domarius
Blank Cone
Blank Cone
Posts: 17
Joined: 28 Apr 2017 22:22

Overlaying my own graphics on the SDL window when VLC is playing

Postby Domarius » 13 Feb 2019 00:30

I want to display text, and a semitransparent menu etc. over the video while the video plays. What is the easiest way to do this? I'm currently using Python and PySDL2 (SDL2 wrapper), and the vlc.py wrapper.

I'm vaguely aware this may involve locking the surface to make it thread safe, but if it would make things easier, I'm willing to compromise and cut the video so only the audio plays while I draw my own graphics.

I'm also willing to switch to C++ if it would mean I'd have an easier time sticking to the more well-trodden path than dealing with these wrappers.

I'm just developing this fake TV software for the Rasperry Pi and thought it would be a good opportunity to try Python and see how easy it is to develop on my desktop and simply copy the files to the Pi and see it run the same way.

Rémi Denis-Courmont
Developer
Developer
Posts: 15266
Joined: 07 Jun 2004 16:01
VLC version: master
Operating System: Linux
Contact:

Re: Overlaying my own graphics on the SDL window when VLC is playing

Postby Rémi Denis-Courmont » 13 Feb 2019 19:31

The easiest way to overlay over VLC is to create a window with alpha channel on top of the VLC window.
Rémi Denis-Courmont
https://www.remlab.net/
Private messages soliciting support will be systematically discarded

Domarius
Blank Cone
Blank Cone
Posts: 17
Joined: 28 Apr 2017 22:22

Re: Overlaying my own graphics on the SDL window when VLC is playing

Postby Domarius » 13 Feb 2019 23:59

Thank you Rémi. Ok so two separate OS windows. But won't this cause the foreground window to take away input from the video window?


Return to “Development around libVLC”

Who is online

Users browsing this forum: No registered users and 24 guests