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 326720 - [alsasink] doesn't support more than 2 channels anymore
[alsasink] doesn't support more than 2 channels anymore
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
Other Linux
: Normal normal
: 0.10.4
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks: 166263 169278
Reported: 2006-01-12 11:43 UTC by Sven Herzberg
Modified: 2006-02-16 21:08 UTC
See Also:
GNOME target: ---
GNOME version: ---

add back multi-channel support to alsasink, attempt #1 (7.65 KB, patch)
2006-01-30 15:30 UTC, Tim-Philipp Müller
none Details | Review
same patch as above, but updated to apply against CVS HEAD (7.78 KB, patch)
2006-02-05 13:23 UTC, Tim-Philipp Müller
none Details | Review

Description Sven Herzberg 2006-01-12 11:43:10 UTC
I used to have this pipeline configured as my audio-sink with 0.8:

audioconvert ! audioscale ! audio/x-raw-int,channels=6,rate=48000 ! alsasink

As the audioscale got renamed I use audioresample now:

audioconvert ! audioresample ! audio/x-raw-int,channels=6,rate=48000 ! alsasink

But this pipeline doen't want to play; I need to change it to this for playing:

audioconvert ! audioresample ! audio/x-raw-int,rate=48000 ! alsasink

But - of course - now I don't get any audio from the center and rear boxes as well as my sub.
Comment 1 Tim-Philipp Müller 2006-01-14 15:43:52 UTC
indee, alsasink doesn't do any caps probing at the moment (this caused a lot of problems in 0.8, so we need to tread carefully when adding it back. Probing the max. number of audio channels should be fairly unproblematic though).
Comment 2 Tim-Philipp Müller 2006-01-30 15:30:45 UTC
Created attachment 58401 [details] [review]
add back multi-channel support to alsasink, attempt #1

First attempt to add back multi-channel support for alsasink, completely untested though, as I have no (working) hardware to test this on at the moment.
Comment 3 Jan Schmidt 2006-01-30 15:40:32 UTC
CC Wim for comment, as he's hacking on audio sinks at the moment.
Comment 4 Baptiste Mille-Mathias 2006-01-30 16:09:09 UTC
CC myself for testing with sb live
Comment 5 Tim-Philipp Müller 2006-02-01 20:04:15 UTC
Sven, in case you didn't get my reply on IRC: could you run

 % GST_DEBUG_NO_COLOR=1  GST_DEBUG=alsa:5,ringbuffer:5,baseaudiosink:5,audiosink:5   gst-launch-0.10 -v audiotestsrc num-buffers=64 ! audioconvert ! audioresample ! audio/x-raw-int,rate=48000,channels=6 ! alsasink device=hw:0   2>&1 | gzip > dbg.log.gz

and attach the log?
Comment 6 Tim-Philipp Müller 2006-02-05 13:23:42 UTC
Created attachment 58760 [details] [review]
same patch as above, but updated to apply against CVS HEAD
Comment 7 Christian Fredrik Kalager Schaller 2006-02-08 22:49:37 UTC
This pipeline produced sound for me on all channels on my USB Audigy2 NX card using this patch:

gst-launch-0.10 filesrc location=bullet.vob ! flupsdemux ! a52dec ! audioconvert ! audioresample ! audio/x-raw-int,channels=6,rate=48000 ! alsasink device=hw:2,0

It seems the system is not able to handle stereo sound sent to 3+ channels, so the sound file needs to be 6 channels for this to work.
Comment 8 Tim-Philipp Müller 2006-02-08 23:51:15 UTC
So when you feed stereo sound, what happens? Do you get an assertion warning? Does it error out? nothing?
Comment 9 Christian Fredrik Kalager Schaller 2006-02-10 11:31:57 UTC
gst-launch-0.10 filesrc location=Little_House_on_the_Prairie.mp3 ! mad ! audioconvert ! audioresample ! audio/x-raw-int,channels=6,rate=48000 ! alsasink device=hw:2,0

This actually works fine, eats CPU like crazy though
Comment 10 Tim-Philipp Müller 2006-02-16 21:08:03 UTC
Committed a version with additional suppport for 2.1 to CVS. If there are any problems with this, I'm sure people will file bugs.

2006-02-16  Tim-Philipp Müller  <tim at centricular dot net>

        * ext/alsa/gstalsasink.c: (gst_alsasink_class_init),
        (gst_alsasink_init), (get_channel_free_structure),
        (caps_add_channel_configuration), (gst_alsasink_getcaps),
        * ext/alsa/gstalsasink.h:
          Add support for more than 2 channels (#326720).