projectm icon indicating copy to clipboard operation
projectm copied to clipboard

[$500 BOUNTY] Implement a cross-platform GStreamer plug-in for libprojectM

Open kblaschke opened this issue 2 years ago • 6 comments

From @revmischa on the projectM Discord Server, 10.11.2022 20:18:

If someone can create a GStreamer plug-in that will enable any sort of custom media pipeline application for projectM. E.g. turn an audio file into a video, create a video from a live stream, overlay or mix visualization on existing video, easy automation, etc.

I'll put a bounty of $500 for whoever lands a working GStreamer plug-in. Paid out of our OpenCollective.

https://gstreamer.freedesktop.org/documentation/plugin-development/index.html?gi-language=c

A few additions/clarifications by me (@kblaschke):

  • The plug-in should compile/work on all platforms supported by both GStreamer and libprojectM.
  • The plug-in should use the new C API that will be released in the libprojectM 4.0 version and link against the shared projectM library (dll/so/dylib). Ideally, wait until after the initial 4.0 release to start the implementation, as the API will still change before the release.
  • The plug-in should consume an audio/x-raw audio stream and pass it on to projectM.
  • The plug-in should produce an video/x-raw video stream as output.

The */x-raw types would probably be the most appropriate input/output formats as they don't require any de-/encoding overhead in the projectM plug-in and has no compression artifacts. While having the highest bit rate, users can put an audio decoder before and a video compressor plug-in after projectM in the GStreamer filter chain if needed.

kblaschke avatar Nov 30 '22 12:11 kblaschke

I would encourage also instead of C to use rust

GStreamer supports rust (docs) and there are many examples of rust plugins

And there are rust bindings for projectM which provide an easier and safer interface to projectM

revmischa avatar Dec 21 '22 20:12 revmischa

Sounds similar to what the gstreamer libvisual integration at https://github.com/GStreamer/gst-plugins-base/tree/master/ext/libvisual is doing. Not sure if that's the latest source.

hartwork avatar Feb 18 '23 23:02 hartwork

For anyone who's interested I have a preliminary working version (on linux at least) here! https://github.com/hashFactory/gst-projectm/

hashFactory avatar Aug 30 '23 09:08 hashFactory

@hashFactory awesome! Any known issues to look-out for ?

luzpaz avatar Feb 07 '24 16:02 luzpaz

This bounty has now been awarded!

You can find the source code here for the official gst-projectm plugin: https://github.com/projectM-visualizer/gst-projectm

blaquewithaq avatar Feb 09 '24 21:02 blaquewithaq

i remember gstreamer plugin was mentioned in the context that it will allow to "convert" mp3 to a video:

https://github.com/projectM-visualizer/projectm/issues/205 https://github.com/projectM-visualizer/projectm/pull/207#issuecomment-543276653

how this could be done now, when the gstreamer support is already implemented?

actionless avatar Mar 29 '24 01:03 actionless