Missing decoder plugin

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Missing decoder plugin

Orko
Hello,

i try to use an ip camera as a webcam for my raspberry pi. there for
installed v4l2loopback and tried
to stream the rtsp stream to /dev/video0  with the command

gst-launch-1.0 rtspsrc location=rtsp://192.168.87.43/ ! decodebin ! v4l2sink
device=/dev/video0

But i get the following error:

Setting pipeline to PAUSED ...
libv4l2: error getting pixformat: Invalid argument
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://192.168.87.43/
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
Progress: (request) Sent PLAY request
Missing element: H.264 (Main Profile) decoder
ERROR: from element /GstPipeline:pipeline0/GstDecodeBin:decodebin0: Your
GStreamer installation is missing a plug-in.
Additional debug info:
gstdecodebin2.c(4592): gst_decode_bin_expose ():
/GstPipeline:pipeline0/GstDecodeBin:decodebin0:
no suitable plugins found:
Missing decoder: H.264 (Main Profile) (video/x-h264,
stream-format=(string)avc, alignment=(string)au,
codec_data=(buffer)014d001fffe10013474d001f99a014016e8400000fa00000fa021001000448ee3c80,
level=(string)3.1, profile=(string)main)

Execution ended after 0:00:02.303332973
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

I'm not sure if the problem is really the missing plugin or this "libv4l2:
error getting pixformat: Invalid argument" .
The rtsp stream is working with vlc the codec is mpeg4 avc.
If i output to a fakesink i get the same decoding error but i have no clue
on how to fix that.
Maybe you guys have an idea of what i'm missing.
Anyway thank you in advance.





--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Missing decoder plugin

gotsring
Can you normally decode H.264 streams? Maybe try installing
gstreamer1.0-libav or gstreamer1.0-omx through the package manager.  Then,
decodebin should be able to use their H.264 decoders (avdec_h264 or
omxh264dec).



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Missing decoder plugin

Nicolas Dufresne-5
In reply to this post by Orko
Le mardi 23 février 2021 à 19:52 -0600, Orko a écrit :

> Hello,
>
> i try to use an ip camera as a webcam for my raspberry pi. there for
> installed v4l2loopback and tried
> to stream the rtsp stream to /dev/video0  with the command
>
> gst-launch-1.0 rtspsrc location=rtsp://192.168.87.43/ ! decodebin ! v4l2sink
> device=/dev/video0
>
> But i get the following error:
>
> Setting pipeline to PAUSED ...
> libv4l2: error getting pixformat: Invalid argument
> Pipeline is live and does not need PREROLL ...
> Progress: (open) Opening Stream
> Progress: (connect) Connecting to rtsp://192.168.87.43/
> Progress: (open) Retrieving server options
> Progress: (open) Retrieving media info
> Progress: (request) SETUP stream 0
> Progress: (open) Opened Stream
> Setting pipeline to PLAYING ...
> New clock: GstSystemClock
> Progress: (request) Sending PLAY request
> Progress: (request) Sending PLAY request
> Progress: (request) Sent PLAY request
> Missing element: H.264 (Main Profile) decoder
> ERROR: from element /GstPipeline:pipeline0/GstDecodeBin:decodebin0: Your
> GStreamer installation is missing a plug-in.
> Additional debug info:
> gstdecodebin2.c(4592): gst_decode_bin_expose ():
> /GstPipeline:pipeline0/GstDecodeBin:decodebin0:
> no suitable plugins found:
> Missing decoder: H.264 (Main Profile) (video/x-h264,
> stream-format=(string)avc, alignment=(string)au,
> codec_data=(buffer)014d001fffe10013474d001f99a014016e8400000fa00000fa021001000
> 448ee3c80,
> level=(string)3.1, profile=(string)main)
>
> Execution ended after 0:00:02.303332973
> Setting pipeline to PAUSED ...
> Setting pipeline to READY ...
> Setting pipeline to NULL ...
> Freeing pipeline ...
>
> I'm not sure if the problem is really the missing plugin or this "libv4l2:
> error getting pixformat: Invalid argument" .
> The rtsp stream is working with vlc the codec is mpeg4 avc.
> If i output to a fakesink i get the same decoding error but i have no clue
> on how to fix that.
> Maybe you guys have an idea of what i'm missing.
> Anyway thank you in advance.

This error trace is from another project, you'd have to look inside of it to
figure-out what it means as clearly there is not enough information.

https://git.linuxtv.org/v4l-utils.git/

>
>
>
>
>
> --
> Sent from: http://gstreamer-devel.966125.n4.nabble.com/
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Missing decoder plugin

Orko
In reply to this post by gotsring
Hello and thank you for your help.

I installed the missing lidav and omx and with:
gst-launch-1.0 rtspsrc location=rtsp://192.168.87.43/ ! decodebin !
autovideosink
i can see the video stream in a window.

But when i try:
gst-launch-1.0 rtspsrc location=rtsp://192.168.87.43/ ! decodebin ! v4l2sink
device=/dev/video0

I get:
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://192.168.87.43/
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
Progress: (open) Opened Stream
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
Progress: (request) Sent PLAY request
ERROR: from element
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstOMXH264Dec-omxh264dec:omxh264dec-omxh264dec0:
Internal data stream error.
Additional debug info:
gstomxvideodec.c(1599): gst_omx_video_dec_loop ():
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstOMXH264Dec-omxh264dec:omxh264dec-omxh264dec0:
stream stopped, reason not-negotiated
Execution ended after 0:00:02.445128941
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

so i think we are getting closer but i do not understand why decodebin now
throws an error.
I thought every element of the pipeline is kinda working separately.?  
 




--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Missing decoder plugin

gotsring
My guess is that it's because v4l2sink has some weirdness where it doesn't
seem to accept GStreamer caps and so it just fails. Therefore, you might
have to convert the video into a format that you specify and add an identity
element before v4l2sink.

Something like
gst-launch-1.0 rtspsrc location=rtsp://192.168.87.43/ ! decodebin !
videoconvert ! video/x-raw, format=YUY2 ! identity drop-allocation=1 !
v4l2sink device=/dev/video0

See this post and the links therein for details:
http://gstreamer-devel.966125.n4.nabble.com/Error-using-v4l2sink-when-combining-2-camera-streams-td4696728.html



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Missing decoder plugin

Orko
So, first of thanks for the help and hints.
I finally managed to make it work here is what i did i'm not sure if this
something that works for others.

1:Setup a v2l4Loopback (A Virtual Video Capture device) info:  here
<https://github.com/umlaeute/v4l2loopback#distributions>  
2:create the device:
sudo modprobe v4l2loopback video_nr=42 card_label=virtcam exclusive_caps=1
max_buffers=2

You can check the device with
v4l2-ctl -d 1 --all

3: start the gstreamer Pipline:
gst-launch-1.0 rtspsrc location=rtsp://192.168.87.43/ ! decodebin !
videoconvert ! video/x-raw, format=YUY2 ! tee ! v4l2sink device=/dev/video42

The problem that i had was is probably  this.
<https://github.com/umlaeute/v4l2loopback/issues/83>  

So now it seems to work chromium finds the camera and shows the image. The
only problem left is that the image is mirrored and i think that's because
of the setting within the v2l4loopback device format.?
I will check that later.





--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel