After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 319784 - mad claims to need more data
mad claims to need more data
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-ugly
git master
Other All
: Normal normal
: 0.9.7
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2005-10-25 20:29 UTC by Luca Ognibene
Modified: 2005-12-01 16:04 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Luca Ognibene 2005-10-25 20:29:35 UTC
Please describe the problem:
Sometimes when playing a video (avi/mpeg4/mp3) totem tells me that it cannot
decode the stream, looking at the GST_DEBUG=*:3 log i can see:

WARN  (0x83310f0 - 0:00:17.696434000)                  mad(18657)
gstmad.c(1283):gst_mad_chain:<mad0> error: mad claims to need more data than
7701 bytes, we don't have that much
INFO  (0x83310f0 - 0:00:18.607176000)     GST_ERROR_SYSTEM(18657)
gstelement.c(1467):gst_element_message_full:<mad0> posting message: Impossibile
decodificare lo stream.

(Impossibile decodificare lo stream = Impossible to decode the stream)

two things:
- it happens only with totem, using playbin from command line works fine
- it happens only sometimes. Others time totem just hangs

I'm using current cvs as of 2005/10/25 19:00 CET and totem head cvs with the
latest 0.9 patch.

Steps to reproduce:
1. Play a file with totem

Actual results:


Expected results:


Does this happen every time?


Other information:
Comment 1 Luca Ognibene 2005-10-25 20:43:46 UTC
GST_DEBUG=*:5 log bzipped at:
http://skaboy.no-ip.org/~luogni/mad-needs-more.log.bz2
Comment 2 Luca Ognibene 2005-11-05 19:01:57 UTC
It seems that:
 - in mad_chain the gst_pad_push call returns GST_FLOW_NOT_LINKED
 - this is handled like an error by mad and so it doesn't decrease the size of
"mad->tempsize"

Doing the change makes disappear this error but then totem will hang :/

backtrace here: http://skaboy.no-ip.org/~luogni/hang-mad-totem
Comment 3 Luca Ognibene 2005-11-15 19:07:31 UTC
Example file here:
http://skaboy.no-ip.org/~luogni/Hellsing%20-%20Order%2000%20-%20Special.avi

I can reproduce it with current cvs of gstreamer and totem. It works fine with
the seek example.
Comment 4 Luca Ognibene 2005-11-16 19:37:12 UTC
If i change totem to use alsasink and xvimagesink instead of gconf* elements
then totem works fine..

Also using auto* elements work fine (using auto* elements trigger a bug in totem
where totem asks the backend if it can seek but the gst 0.10 backend doesn't
know yet if it can seek or not and so the seek bar in totem is disabled). If i
change totem source code and make it to always enable the seek bar then all work
fine.

I don't know if the gconf* elements trigger a bug in the core or if they are
just borked..
Comment 5 Tim-Philipp Müller 2005-11-22 19:26:06 UTC
I get this error from time to time in totem as well.

I can reproduce it by loading a playlist of mp3 files and switching frequently
between the files (with visualisation enabled here). Usually it will error out
with a random 'cannot decode stream' error message after less than 20 or so
changes. I say 'random' because the same files that error out sometimes will
play fine at other times.

The error message in the logs is the same as the one mentioned above ('mad
claims to need more than x bytes, but we only have N').
Comment 6 Jan Schmidt 2005-11-25 00:04:54 UTC
Fixed in CVS:
        * ext/mad/gstmad.c: (gst_mad_chain):
        When pad_alloc returns other-than-GST_FLOW_OK and mad exits early,
        skip frame synthesis and consume input data as if we'd done the
        decode. Makes mad not error when the src pad is not connected.
        (#319784)