omxh264dec and textoverlay

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

omxh264dec and textoverlay

imeshns
I have raspberry pi 3 and 2016-05-27-raspbian-jessie. When I create test with gst-inspect-1.0:

GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://... ! rtph264depay ! h264parse ! omxh264dec ! textoverlay ! glimagesink

everyting is okey and video can play, but if I only adds attribute text="test" to the textoverlay, the debugger shows me errors:

Progress: (request) Sent PLAY request
0:00:00.467385197  1120 0x7200ecc0 WARN         rtpjitterbuffer rtpjitterbuffer.c:185:rtp_jitter_buffer_set_clock_rate: Clock rate changed from 0 to 8000
0:00:00.586528630  1120 0x7200ecc0 WARN                 basesrc gstbasesrc.c:2933:gst_base_src_loop:<udpsrc4> error: Internal data flow error.
0:00:00.586603838  1120 0x7200ecc0 WARN                 basesrc gstbasesrc.c:2933:gst_base_src_loop:<udpsrc4> error: streaming task paused, reason not-linked (-1)
0:00:01.360516367  1120 0x7200ec60 WARN         rtpjitterbuffer rtpjitterbuffer.c:185:rtp_jitter_buffer_set_clock_rate: Clock rate changed from 0 to 90000
0:00:01.627790242  1120 0x70c0f920 ERROR             GST_MEMORY gstmemory.c:318:gst_memory_map: mem 0x72053c00: subclass map failed
0:00:01.628354614  1120 0x70c0f920 ERROR                default video-frame.c:138:gst_video_frame_map_id: failed to map video frame plane 0
0:00:01.644408786  1120 0x70c0f920 ERROR             GST_MEMORY gstmemory.c:318:gst_memory_map: mem 0x6f906b20: subclass map failed
0:00:01.644858262  1120 0x70c0f920 ERROR                default video-frame.c:138:gst_video_frame_map_id: failed to map video frame plane 0
0:00:01.645650028  1120 0x70c0f920 ERROR             GST_MEMORY gstmemory.c:318:gst_memory_map: mem 0x6f906a70: subclass map failed
0:00:01.646103984  1120 0x70c0f920 ERROR                default video-frame.c:138:gst_video_frame_map_id: failed to map video frame plane 0
0:00:01.646585023  1120 0x70c0f920 ERROR             GST_MEMORY gstmemory.c:318:gst_memory_map: mem 0x6f9069c0: subclass map failed
0:00:01.646814813  1120 0x70c0f920 ERROR                default video-frame.c:138:gst_video_frame_map_id: failed to map video frame plane 0

Is there any solution to overlay text on the glimagesink with hardware acceleration "omxh264dec" on raspberry pi?

Thanks for all help.

Reply | Threaded
Open this post in threaded view
|

Re: omxh264dec and textoverlay

Sebastian Dröge-3
On Mon, 2016-09-05 at 02:46 -0700, imeshns wrote:

> I have raspberry pi 3 and 2016-05-27-raspbian-jessie. When I create
> test with
> gst-inspect-1.0:
>
> GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://... ! rtph264depay
> !
> h264parse ! omxh264dec ! textoverlay ! glimagesink
>
> everyting is okey and video can play, but if I only adds attribute
> text="test" to the textoverlay, the debugger shows me errors:
> [...]
> 0:00:01.646814813  1120 0x70c0f920 ERROR                default
> video-frame.c:138:gst_video_frame_map_id: failed to map video frame
> plane 0
>
> Is there any solution to overlay text on the glimagesink with
> hardware acceleration "omxh264dec" on raspberry pi?
Which version of GStreamer is that with (also of gst-omx)? 1.8 and
newer should be able to handle this properly by delaying the overlaying
to the sink.


Independent of that, even in older versions this shouldn't fail like
that but just be extremely slow.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (949 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: omxh264dec and textoverlay

imeshns
That's my version of GStreamer on Raspberry Pi 3:

pi@raspberrypi:~ $ dpkg -l | grep gstreamer
ii  gir1.2-gstreamer-1.0                  1.4.4-2                                   armhf        Description: GObject introspection data for the GStreamer library
ii  gstreamer0.10-alsa:armhf              0.10.36-2                                 armhf        GStreamer plugin for ALSA
ii  gstreamer0.10-plugins-base:armhf      0.10.36-2                                 armhf        GStreamer plugins from the "base" set
ii  gstreamer1.0-alsa:armhf               1.4.4-2                                   armhf        GStreamer plugin for ALSA
ii  gstreamer1.0-libav:armhf              1.4.4-2                                   armhf        libav plugin for GStreamer
ii  gstreamer1.0-omx                      1.0.0.1-0+rpi18rpi1g                      armhf        GStreamer OpenMAX plugins
ii  gstreamer1.0-plugins-bad:armhf        1.4.4-2.1rpi4rpi1g                        armhf        GStreamer plugins from the "bad" set
ii  gstreamer1.0-plugins-base:armhf       1.4.4-2                                   armhf        GStreamer plugins from the "base" set
ii  gstreamer1.0-plugins-good:armhf       1.4.4-2                                   armhf        GStreamer plugins from the "good" set
ii  gstreamer1.0-tools                    1.4.4-2                                   armhf        Tools for use with GStreamer
ii  gstreamer1.0-x:armhf                  1.4.4-2                                   armhf        GStreamer plugins for X11 and Pango
ii  libgstreamer-plugins-bad1.0-0:armhf   1.4.4-2.1rpi4rpi1g                        armhf        GStreamer development files for libraries from the "bad" set
ii  libgstreamer-plugins-bad1.0-dev       1.4.4-2.1rpi4rpi1g                        armhf        GStreamer development files for libraries from the "bad" set
ii  libgstreamer-plugins-base0.10-0:armhf 0.10.36-2                                 armhf        GStreamer libraries from the "base" set
ii  libgstreamer-plugins-base1.0-0:armhf  1.4.4-2                                   armhf        GStreamer libraries from the "base" set
ii  libgstreamer-plugins-base1.0-dev      1.4.4-2                                   armhf        GStreamer development files for libraries from the "base" set
ii  libgstreamer0.10-0:armhf              0.10.36-1.5                               armhf        Core GStreamer libraries and elements
ii  libgstreamer1.0-0:armhf               1.4.4-2                                   armhf        Core GStreamer libraries and elements
ii  libgstreamer1.0-dev                   1.4.4-2                                   armhf        GStreamer core development files
ii  libreoffice-avmedia-backend-gstreamer 1:4.3.3-2+rpi3                            armhf        GStreamer backend for LibreOffice
pi@raspberrypi:~ $ gst-launch-1.0 --version
gst-launch-1.0 version 1.4.4
GStreamer 1.4.4
http://packages.qa.debian.org/gstreamer1.0
Reply | Threaded
Open this post in threaded view
|

Re: omxh264dec and textoverlay

Sebastian Dröge-3
On Wed, 2016-09-07 at 01:12 -0700, imeshns wrote:

> That's my version of GStreamer on Raspberry Pi 3:
>
> pi@raspberrypi:~ $ dpkg -l | grep gstreamer
>           
> armhf        GStreamer plugins for X11 and Pango
> ii  libgstreamer-plugins-bad1.0-0:armhf   1.4.4-2.1rpi4rpi1g                       
> armhf        GStreamer development files for libraries from the "bad" set
> ii  libgstreamer-plugins-bad1.0-dev       1.4.4-2.1rpi4rpi1g                       
> armhf        GStreamer development files for libraries from the "bad" set
> ii  libgstreamer-plugins-base1.0-0:armhf  1.4.4-2                                  
> armhf        GStreamer libraries from the "base" set
> ii  libgstreamer-plugins-base1.0-dev      1.4.4-2                                  
> armhf        GStreamer development files for libraries from the "base" set
Those are rather old versions and don't have anything for proper
rendering of text over the video without going through the CPU.

They still shouldn't fail that way (and just be very slow), but that
might be a change done by the RPi people or something that is long
fixed in newer versions already. AFAIU what you're trying to do works
with the latest versions.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (949 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: omxh264dec and textoverlay

imeshns
Okay thanks. I have the latest version of GStreamer and I can add textoverlay. But now when I change glimagesink to fakesink:

GST_DEBUG=3 gst-launch-1.0 rtspsrc location=rtsp://... ! rtph264depay ! h264parse ! omxh264dec ! fakesink

the debugger shows me that:

0:00:03.113184703 17085 0x70f4a830 ERROR            omxvideodec gstomxvideodec.c:974:gst_omx_video_dec_reconfigure_output_port:<omxh264dec-omxh264dec0> Failed to negotiate RGBA for EGLImage

At the previous version I hadn't this error.

And the second warning which the debugger shows cyclic:

0:00:03.310577934 17145 0x73354c60 WARN             omxvideodec gstomxvideodec.c:1390:gst_omx_video_dec_loop:<omxh264dec-omxh264dec0> Frame is too late, dropping (deadline 0:00:00.138325446)

Is the reason for this is the performance of the hardware decoder in raspberry?

Thanks for all help
Reply | Threaded
Open this post in threaded view
|

Re: omxh264dec and textoverlay

Sebastian Dröge-3
On Mo, 2016-09-12 at 05:17 -0700, imeshns wrote:

> Is the reason for this is the performance of the hardware decoder in
> raspberry?

Rendering to fakesink requires copying all frames to the CPU, which is
slow. Use a glimagesink.

Also don't use nabble to reply to mails, it creates incomplete and
broken mails as the one you just created.

--
Sebastian Dröge, Centricular Ltd · http://www.centricular.com
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

signature.asc (985 bytes) Download Attachment