How would I be able to add live "broadcast" graphics on top of a gstreamer video. By broadcast I think of something like a scoreboard or news. It would be cool if there was some way of drawing html on top of it, since this would allow some simple animations using CSS and maybe javascript.
The key requirement though is the ability to manipulate graphics overlayed a video, while it is playing live. Therefore it would be ideal if the graphics didn't have to be pre-rendered with text for say each player.
Currently my application is written in GTK C and gstreamer, and I have been looking at achieving something with Cairo and cairooverlay
.
I have also been looking at this concept, but I am not sure if this will work with GTK.
There is a Gtk solution on github https://github.com/Kalyzee/gst-webkit.
First compile & install as described in docs. To test it I just needed to add "enabled=1" to the test command line to make it work.
GST_DEBUG=*webkit*:5 gst-launch-1.0 webkitsrc enabled=1 url="https://www.google.com/" ! video/x-raw, format=RGBA, framerate=25/1, width=1280, height=720 ! videoconvert ! xvimagesink sync=FALSE
(Note: on Ubuntu 16.04 I needed to install libwebkit2gtk-4.0-dev. For some reason libwebkit-dev was not sufficent)