Constant avdec_h264: decoding error

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

Constant avdec_h264: decoding error

Juan Navarro
I'm getting a continuous stream of WARN and ERROR messages when trying
to play an RTSP source, due to issues in the H.264 decoding done by
avdec_h264.

This is a (truncated) sample of the messages:

0:00:02.186 WARN  libav gstavcodecmap.c:2441:gst_ffmpeg_caps_to_pixfmt:
ignoring insane framerate 1/0
0:00:02.187 ERROR libav :0:: no frame!
0:00:02.187 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.189 ERROR libav :0:: left block unavailable for requested intra
mode at 0 2
0:00:02.189 ERROR libav :0:: error while decoding MB 0 2, bytestream 10023
0:00:02.201 ERROR libav :0:: no frame!
0:00:02.201 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.202 ERROR libav :0:: no frame!
0:00:02.202 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.202 ERROR libav :0:: Reference 4 >= 2
0:00:02.202 ERROR libav :0:: error while decoding MB 35 4, bytestream 2615
0:00:02.202 ERROR libav :0:: no frame!
0:00:02.202 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.204 ERROR libav :0:: Reference 2 >= 2
0:00:02.204 ERROR libav :0:: error while decoding MB 29 4, bytestream 3647
0:00:02.209 ERROR libav :0:: no frame!
0:00:02.209 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.209 ERROR libav :0:: Reference 3 >= 2
0:00:02.209 ERROR libav :0:: error while decoding MB 36 10, bytestream 4386
0:00:02.210 ERROR libav :0:: no frame!

As you can see from the timestamps, these are printed dozens of times
per second.

The RTSP stream used to get these errors is this one:

rtsp://95.131.167.44:554/10701947

Hopefully this stays accessible for the next days / weeks.


My gst-launch command is like this:

gst-launch-1.0 \
     rtspsrc location="rtsp://95.131.167.44:554/10701947" protocols="tcp" \
     ! "application/x-rtp, media=(string)video" \
     ! decodebin \
     ! autovideosink

Of course, a completely manual equivalent has the same issues:

gst-launch-1.0 \
     rtspsrc location="rtsp://95.131.167.44:554/10701947" protocols="tcp" \
     ! "application/x-rtp, media=(string)video" \
     ! rtph264depay \
     ! h264parse \
     ! avdec_h264 \
     ! autovideosink

I have been able to test and got same results with the GStreamer
versions available in Ubuntu 16.04 (Gstreamer 1.8.3), 18.04 (GStreamer
1.14.5), and 20.04 (GStreamer 1.16.2).

Curious thing is that even despite all those errors and warnings, the
end result seems to be playing back fluidly and without issues. Also if
audio is added to the pipeline, it also is correct and synchronized with
the video. Nevertheless, all those warnings must be indicating some
issue that is ingrained in the encoding of the video, and I'd love some
help figuring out if there is something a receiver application can do to
solve it, or if there might be a bug to be reported in the decoder itself.

Thanks!
Juan Navarro

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

AW: Constant avdec_h264: decoding error

Thornton, Keith
Hi, what does the encoding side look like?

-----Ursprüngliche Nachricht-----
Von: gstreamer-devel <[hidden email]> Im Auftrag von Juan Navarro
Gesendet: Mittwoch, 29. April 2020 17:28
An: [hidden email]
Betreff: Constant avdec_h264: decoding error

I'm getting a continuous stream of WARN and ERROR messages when trying to play an RTSP source, due to issues in the H.264 decoding done by avdec_h264.

This is a (truncated) sample of the messages:

0:00:02.186 WARN  libav gstavcodecmap.c:2441:gst_ffmpeg_caps_to_pixfmt:
ignoring insane framerate 1/0
0:00:02.187 ERROR libav :0:: no frame!
0:00:02.187 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.189 ERROR libav :0:: left block unavailable for requested intra mode at 0 2
0:00:02.189 ERROR libav :0:: error while decoding MB 0 2, bytestream 10023
0:00:02.201 ERROR libav :0:: no frame!
0:00:02.201 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.202 ERROR libav :0:: no frame!
0:00:02.202 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.202 ERROR libav :0:: Reference 4 >= 2
0:00:02.202 ERROR libav :0:: error while decoding MB 35 4, bytestream 2615
0:00:02.202 ERROR libav :0:: no frame!
0:00:02.202 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.204 ERROR libav :0:: Reference 2 >= 2
0:00:02.204 ERROR libav :0:: error while decoding MB 29 4, bytestream 3647
0:00:02.209 ERROR libav :0:: no frame!
0:00:02.209 WARN  libav
gstavviddec.c:1535:gst_ffmpegviddec_frame:<avdec_h264-0> avdec_h264:
decoding error (len: -1094995529, have_data: 0)
0:00:02.209 ERROR libav :0:: Reference 3 >= 2
0:00:02.209 ERROR libav :0:: error while decoding MB 36 10, bytestream 4386
0:00:02.210 ERROR libav :0:: no frame!

As you can see from the timestamps, these are printed dozens of times per second.

The RTSP stream used to get these errors is this one:

rtsp://95.131.167.44:554/10701947

Hopefully this stays accessible for the next days / weeks.


My gst-launch command is like this:

gst-launch-1.0 \
     rtspsrc location="rtsp://95.131.167.44:554/10701947" protocols="tcp" \
     ! "application/x-rtp, media=(string)video" \
     ! decodebin \
     ! autovideosink

Of course, a completely manual equivalent has the same issues:

gst-launch-1.0 \
     rtspsrc location="rtsp://95.131.167.44:554/10701947" protocols="tcp" \
     ! "application/x-rtp, media=(string)video" \
     ! rtph264depay \
     ! h264parse \
     ! avdec_h264 \
     ! autovideosink

I have been able to test and got same results with the GStreamer versions available in Ubuntu 16.04 (Gstreamer 1.8.3), 18.04 (GStreamer 1.14.5), and 20.04 (GStreamer 1.16.2).

Curious thing is that even despite all those errors and warnings, the end result seems to be playing back fluidly and without issues. Also if audio is added to the pipeline, it also is correct and synchronized with the video. Nevertheless, all those warnings must be indicating some issue that is ingrained in the encoding of the video, and I'd love some help figuring out if there is something a receiver application can do to solve it, or if there might be a bug to be reported in the decoder itself.

Thanks!
Juan Navarro

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://eur01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Fgstreamer-devel&amp;data=02%7C01%7C%7C247aecc1b5f24019c04308d7ec5cc948%7C28042244bb514cd680347776fa3703e8%7C1%7C0%7C637237755564796300&amp;sdata=iebAPwkL5qI99xhcI3cMSlyi9zQrWJsQNgAd%2FeXDuV8%3D&amp;reserved=0
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Constant avdec_h264: decoding error

Stephenwei
In reply to this post by Juan Navarro
gst-launch-1.0 rtspsrc location=rtsp://95.131.167.44:554/10701947 !
rtph264depay ! h264parse ! avdec_h264 ! videoconvert ! ximagesink

works fine.



-----
GStreamer is a convenient multimedia platform, I like it.
Develop the NVR system on ARM/x86(c/python)
Use python to generate NVR is crazy, of course works fine.

--
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: Constant avdec_h264: decoding error

Juan Navarro
In reply to this post by Thornton, Keith
I wanted to have some more info for today, but seems the info will take
a bit more to arrive. The stream is from a local TV station, and from
the comments I've received it seems to be generated by a hardware
encoder called Teradek Cube:
https://teradek.com/products/cube-755?variant=39287505869#techSpecs

I'll update as soon as I get more detailed information about the
settings on this device.

Regarding the errors, in my original email I didn't include the fact
that logging must be enabled to see them, just for the sake of
completeness this is the whole set of commands needed to install
GStreamer and see the stream that causes decoding errors:

# Debian/Ubuntu install
sudo apt-get update && sudo apt-get install --no-install-recommends \
     gstreamer1.0-libav \
     gstreamer1.0-plugins-{good,bad,ugly} \
     gstreamer1.0-tools

export GST_DEBUG=3

gst-launch-1.0 \
     rtspsrc location="rtsp://95.131.167.44:554/10701947" protocols="tcp" \
     ! "application/x-rtp, media=(string)video" \
     ! decodebin \
     ! autovideosink

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel