fallbacksrc plugin with stream HTTP/MJPEG

Alejandro Vazquez avazquez.dev at gmail.com
Fri Nov 5 08:58:11 UTC 2021


Hi all.
I use Gstreamer to handle a Webcam streaming with MJPG-Streamer on my
local network through the HTTP protocol. I think that the plugin
fallbacksrc is a good idea to solve network stability problems.

So, I have the following scenario:
- Webcam streaming with MJPG-Streamer
- Mini-app with plugin fallbacksrc.Code->https://acortar.link/bbM0Zt

To play the webcam streaming correctly with gstreamer, I need to add
the caps: "image/jpeg,framerate=0/1", otherwise the video will stutter
or even freeze.
For this I am using a pipeline which is equivalent to this one:

gst-launch-1.0 souphttpsrc is-live=true location=<MJPGStreamer_Url> !
multipartdemux ! image/jpeg,framerate=0/1 ! jpegparse ! avdec_mjpeg !
videoconvert ! autovideosink

The problem, in my mini-app, is that if I set the framerate=0/1,
immediately I start the stream, it receives the End-of-stream signal
and my mini-app dont't work, however if I do not set the framerate, It
don't receive that signal (eof) and my mini-app work but the video
will stutter.

Are there any options to solve this problem?

Versions
- Gstreamer and plugins 1.18.5
- Plugins rust: 0.7.2.


More information about the gstreamer-devel mailing list