Why Gstreamer?

I offered my services for an upcoming youth retreat and thought I’d download the latest and greatest Quelea first. Unfortunately video through Gstreamer did not work well for me. When adding a video to the service order, it played back as expected, though not smoothly - it lagged in places. Trying to add a video to a theme crashed quelea to the point of having to kill the task. I installed the latest CI release and was able to create the theme, but when I went live with the song, it took forever to come up and everything froze.

I uninstalled 2024 and went back to 2022 with the latest VLC - Everything works perfect.

I am curious what was the motive for moving off VLC in favor of Gstreamer? Are there additional features that Quelea can leverage? VLC has been around forever and is many users’ gold standard for video playback. Gstreamer looks to be a 1.0 release with no track record.

Until this is more stable, perhaps an option could be added in the Settings to select whether to use VLC or Gstreamer - kind of like Open Office or PowerPoint.

Ah, the joys of cross-platform video!

It’s a tough one. VLC had lots of issues on lots of platforms - it runs as a separate window underneath the main display, and we have to line the two up. On some platforms that use scaling, it’s very hard (or impossible) to get the maths right on that, particularly if the OS doesn’t report the scaling accurately - so we had lots of cases of the video background and the text simply not aligning. It also had lots of issues with different versions working or not working depending on a bunch of factors that also differed from OS to OS, and it only reliably allowed one video per process, meaning we couldn’t animate things like video previews (for example). There were a bunch of more minor issues too. tl;dr it worked fine for some setups, but had major limitations for others.

GStreamer is actually the same age as VLC - it’s been around forever and has a huge track record, though people tend not to have heard of it because it’s primarily a library more than a player. It’s much more flexible, extensible and reliable version to version than VLC, and the version numbering is much more conservative (it’s not less stable because it’s only a 1.0 release.)

The reason it has limitations in Quelea is twofold - firstly, I added it everywhere without the ability to turn it off which probably wasn’t the best idea (everything like video previews are now animated when they weren’t before.) This works fine on some systems, but on lower spec ones it’s more resources than the machine can sensibly handle, which is probably the cause of the stutters and freezes. That’s one I can solve by adding an option.

The second one is more complex - and that’s because while GStreamer leverages the GPU to decode super-fast, most videos these days are encoded in a variant of YUV, and JavaFX can only natively handle RGB. So the buffer has to be converted rather than displayed directly, and that’s what takes the time and causes the lag spikes (not GStreamer). There are ways of addressing that I’m considering, but none of them are quick & easy, unfortunately. It is still on the cards though.

Hope that gives some context at least!

Thanks Michael - I appreciate the response and all the time and effort you put into making Quelea great!

There is a massive playback/GStreamer memory leak Ridiculous RAM usage problem! - #3 by JessyJP