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 140565 - gst-launch caused an Internal GStreamer error
gst-launch caused an Internal GStreamer error
Status: VERIFIED INCOMPLETE
Product: GStreamer
Classification: Platform
Component: gstreamer (core)
git master
Other FreeBSD
: Normal normal
: NONE
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2004-04-20 03:58 UTC by Andrew Turner
Modified: 2009-08-15 18:40 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Output from failed pipeline with --gst-debug=oss:5 (5.85 KB, text/plain)
2004-04-21 10:34 UTC, Andrew Turner
Details
Output from failed pipeline with audioscale before osssink (9.79 KB, text/plain)
2004-04-21 22:49 UTC, Andrew Turner
Details

Description Andrew Turner 2004-04-20 03:58:36 UTC
Running the following with causes an Internal GStreamer error aswell as other
errors.

gst-launch-0.8 filesrc location=file.ogg ! oggdemux ! vorbisdec ! audioconvert !
osssink

Output to console:

RUNNING pipeline ...
ERROR         default(35591) ./grammar.y(374):gst_parse_element_lock:<osssink0>
(null)
ERROR         default(35591) ./grammar.y(374):gst_parse_element_lock:<osssink0>
(null)
ERROR: from element /pipeline0/osssink0: Internal GStreamer error: state change
failed.  File a bug.

(process:35591): GStreamer-CRITICAL **: file gstelement.c: line 913
(gst_element_set_time_delay): assertion `element->current_state >=
GST_STATE_PAUSED' failed
ERROR       scheduler(35591)
gstoptimalscheduler.c(2298):gst_opt_scheduler_iterate:<GstOptScheduler@0x80caf00>
in error state
Execution ended after 1041 iterations (sum 270865000 ns, average 260196 ns, min
63000 ns, max 126559000 ns).
Comment 1 Johan (not receiving bugmail) Dahlin 2004-04-20 10:00:33 UTC
I can not reproduce, can you reproduce with all your oggs? If it's only for a
specific ogg then add a link here. 
Are you really using latest cvs of both gstreamer and gst-plugins?
Comment 2 Andrew Turner 2004-04-21 00:07:04 UTC
This is with latest cvs.

I don't have this problem with 0.8.0 but do with 0.8.1
I don't have the problem with artsdsink, esdsink or fakesink.
Playing an mp3 with "filesrc location=file.mp3 ! mad ! osssink" dosn't display
the same message but it still won't play.

Replacing libgstossaudio.so with the 0.8.0 version makes it work for ogg and mp3.
Comment 3 David Schleef 2004-04-21 00:35:02 UTC
Could you add an audioconvert element before osssink and see if that makes a
difference?  In either case, could you also run the failing pipeline with
--gst-debug=oss:5 and attach the output?
Comment 4 Andrew Turner 2004-04-21 10:34:55 UTC
Created attachment 26908 [details]
Output from failed pipeline with --gst-debug=oss:5
Comment 5 Andrew Turner 2004-04-21 10:43:36 UTC
David there was already an audioconvert element before the osssink.

Without the audioconvert element GStreamer complains it can't link vorbisdec0 to
osssink0.
Comment 6 David Schleef 2004-04-21 18:03:44 UTC
Er, that was supposed to be "audioscale".  Sorry.
Comment 7 Andrew Turner 2004-04-21 22:49:44 UTC
Created attachment 26941 [details]
Output from failed pipeline with audioscale before osssink
Comment 8 David Schleef 2004-04-29 03:51:53 UTC
You have a sound card/driver that claims to only support 8000 Hz for every
format.  I find this rather hard to believe, so it's probably a driver bug. 
What device and driver is it?
Comment 9 Andrew Turner 2004-04-29 22:59:38 UTC
The card is:

pcm0: <VIA VT82C686A> port 0xb000-0xb003,0xb400-0xb403,0xb800-0xb8ff irq 12 at
device 7.5 on pci0
pcm0: <Avance Logic ALC200 AC97 Codec>

I found the problem to be when the SNDCTL_DSP_SPEED ioctl is called with a value
> 48500 it returns 8000.

If I change gstosselement.c line 1170 from
probe->max = gst_osselement_rate_check_rate (probe, 100000);
to
probe->max = gst_osselement_rate_check_rate (probe, 48500);
gst-launch will work.
Comment 10 David Schleef 2004-04-29 23:31:14 UTC
Ok, cool, thanks for checking this.

That's obviously a driver bug.  I added a little check for it, so you won't have
the problem anymore.  You'll get an error message, though.

What kernel version are you using?  I can't seem to find the relevant kernel code.
Comment 11 Thomas Vander Stichele 2004-07-06 12:02:43 UTC
ping
Comment 12 Andrew Turner 2004-07-07 04:53:17 UTC
I'm using 5.2.1-RELEASE

Src locations for the dsp ioctl's are here:

Kernel ioctl handler function is located at
http://fxr.watson.org/fxr/source/dev/sound/pcm/dsp.c?v=RELENG52#L445

SNDCTL_DSP_SPEED specific code is at
http://fxr.watson.org/fxr/source/dev/sound/pcm/dsp.c?v=RELENG52#L683
Comment 13 Christian Fredrik Kalager Schaller 2004-12-07 23:56:51 UTC
Ok, marking this as closed as David resolved the issue with a workaround.