[gstreamer-bugs] [Bug 613567] Cannot query stream duration in playbin2 when GST_MESSAGE_DURATION appears on the bus.

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Wed Mar 24 02:43:41 PDT 2010


https://bugzilla.gnome.org/show_bug.cgi?id=613567
  GStreamer | gstreamer (core) | 0.10.28

Wim Taymans <wim.taymans> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |NOTABUG

--- Comment #7 from Wim Taymans <wim.taymans at gmail.com> 2010-03-24 09:43:37 UTC ---
(In reply to comment #6)
> It's probably not a bug, but I'm having the same issue and not being able to do
> a duration query after receiving the GST_MESSAGE_DURATION on the bus doesn't
> seem very logical to me.

Maybe it's not logical but that is what it is. You can't query the duration as
soon as you get a
duration message, you have to wait until the pipeline completes the state
change to PAUSED.
The duration message is there to inform you about duration changes *after*
going to the 
PAUSED state.

> My player is based on totem and it has been working since the last GStreamer
> release, but after the last GStreamer update I can't query the duration after
> receiving the GST_MESSAGE_DURATION in the bus anymore and I have to do it in
> the READY to PAUSED transition. (This happens on Windows XP, I'll try later on
> linux, but I don't think it will happen since many people should have tested
> totem with the last GStreamer release :P)

It's possible that the duration message is now emitted earlier. That is no
problem as long as you don't use the duration message as the signal that it's
safe to query the duration.

> If this is not the expected behavior why does totem relies on it  and even
> prints a debug message when this happens?
> http://git.gnome.org/browse/totem/tree/src/backend/bacon-video-widget-gst-0.10.c#n2165
> I fixed it in my player with the following patch:
> http://git.gnome.org/browse/longomatch/commit/?id=04d2eaaa9132cc64e5d0ed77508a0a7d1d2bd29d
> 

*after* going to paused, duration messages can be used to trigger a duration
query. Before going to PAUSED the duration query will fail. Totem does the
right thing, if it gets a duration message, it
tries to query for the duration (but doesn't fail when the query fails). Totem
also has a timeout
scheduled to query the duration after PAUSED.

> Can you please confirm that this is not really a bug (maybe playbin2 is posting
> this message too soon or maybe it only happens on windows), and that what is
> done in totem is not the good approach?

As said before, it is not a bug and intended behaviour.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.




More information about the Gstreamer-bugs mailing list