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 161704 - [alsasink] need probing of HW/device supported sample rates
[alsasink] need probing of HW/device supported sample rates
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins
git master
Other Linux
: Normal normal
: NONE
Assigned To: Stephane Loeuillet
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2004-12-19 14:26 UTC by Stephane Loeuillet
Modified: 2005-06-30 15:41 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
au file with 8012Hz mono sound (1.64 KB, application/octet-stream)
2004-12-19 14:42 UTC, Stephane Loeuillet
Details
alsa error log with mvi33.avi file in totem (18.12 KB, text/plain)
2004-12-19 14:50 UTC, Stephane Loeuillet
Details
HW sample rate probing for alsa (1.37 KB, text/plain)
2004-12-19 23:09 UTC, Stephane Loeuillet
Details
gst_alsa_rateprobe.tar.bz2 (10.00 KB, application/x-bzip2)
2004-12-20 23:11 UTC, Stephane Loeuillet
Details
gst_alsa_rateprobe.tar.bz2 (10.00 KB, application/x-bzip2)
2004-12-21 00:03 UTC, Stephane Loeuillet
Details

Description Stephane Loeuillet 2004-12-19 14:26:38 UTC
this bug is a spin of bug #160116 (same avi file, different issue)

so, with the mvi_0033.avi file, i've got this output :
** (totem:16929): WARNING **: could not link audio/x-raw-int,
endianness=(int)1234, width=(int)8, depth=(int)8, signed=(boolean)false,
rate=(int)11024, channels=(int)1, codec_data=(buffer)000001000800

no audio is played, video stops shortly


if i set my default audiosink to esdsink (which uses alsa hw:0), i've got sound
and file is played in its integrality
Comment 1 Stephane Loeuillet 2004-12-19 14:41:03 UTC
got the same issue with a "au" file, containing 8012Hz audio

attaching it now (small)
Comment 2 Stephane Loeuillet 2004-12-19 14:42:31 UTC
Created attachment 35004 [details]
au file with 8012Hz mono sound

** (totem:26606): WARNING **: could not link audio/x-raw-int, width=(int)16,
depth=(int)16, signed=(boolean)true, endianness=(int)1234, rate=(int)8012,
channels=(int)1
Comment 3 Stephane Loeuillet 2004-12-19 14:48:45 UTC
INFO  (0x80870a0 - 306518:47:32.582044000)            alsa(26646)
gstalsa.c(1371):gst_alsa_open_audio: Opening alsa device "default"...
INFO  (0x80870a0 - 306518:47:32.877949000)            alsa(26646)
gstalsa.c(1371):gst_alsa_open_audio: Opening alsa device "default"...
LOG   (0x80870a0 - 306518:47:33.033562000)            alsa(26646)
gstalsa.c(920):gst_alsa_get_caps:<alsasink0> get_caps returns audio/x-alaw,
rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2 }; audio/x-alaw, rate=(int)[
8000, 192000 ], channels=(int)4, channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-alaw, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-alaw, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-mulaw, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2 };
audio/x-mulaw, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-mulaw, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-mulaw, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-float, buffer-frames=(int)[ 0, 2147483647 ], width=(int){ 64, 32 },
endianness=(int)1234, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2 };
audio/x-raw-float, buffer-frames=(int)[ 0, 2147483647 ], width=(int){ 32, 64 },
endianness=(int)1234, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-float, buffer-frames=(int)[ 0, 2147483647 ], width=(int){ 32, 64 },
endianness=(int)1234, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-float, buffer-frames=(int)[ 0, 2147483647 ], width=(int){ 32, 64 },
endianness=(int)1234, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)8, depth=(int)8, signed=(boolean){ false, true },
rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2 }; audio/x-raw-int,
width=(int)8, depth=(int)8, signed=(boolean){ true, false }, rate=(int)[ 8000,
192000 ], channels=(int)4, channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)8, depth=(int)8, signed=(boolean){ true, false },
rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)8, depth=(int)8, signed=(boolean){ true, false },
rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)16, depth=(int)16, signed=(boolean)true,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)16, depth=(int)16, signed=(boolean)false,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)32, depth=(int)24, signed=(boolean)true,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)32, depth=(int)24, signed=(boolean)false,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)32, depth=(int)32, signed=(boolean)true,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)32, depth=(int)32, signed=(boolean)false,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)24, depth=(int)24, signed=(boolean)true,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)24, depth=(int)24, signed=(boolean)false,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)24, depth=(int)20, signed=(boolean)true,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)24, depth=(int)20, signed=(boolean)false,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)24, depth=(int)18, signed=(boolean)true,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)24, depth=(int)18, signed=(boolean)false,
endianness=(int){ 4321, 1234 }, rate=(int)[ 8000, 192000 ], channels=(int){ 1, 2
}; audio/x-raw-int, width=(int)16, depth=(int)16, signed=(boolean){ false, true
}, endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)16, depth=(int)16, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)16, depth=(int)16, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)32, depth=(int)24, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)32, depth=(int)24, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)32, depth=(int)24, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)32, depth=(int)32, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)32, depth=(int)32, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)32, depth=(int)32, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)24, depth=(int)24, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)24, depth=(int)24, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)24, depth=(int)24, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)24, depth=(int)20, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)24, depth=(int)20, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)24, depth=(int)20, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >;
audio/x-raw-int, width=(int)24, depth=(int)18, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)4,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT >;
audio/x-raw-int, width=(int)24, depth=(int)18, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)6,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE >;
audio/x-raw-int, width=(int)24, depth=(int)18, signed=(boolean){ false, true },
endianness=(int){ 1234, 4321 }, rate=(int)[ 8000, 192000 ], channels=(int)8,
channel-positions=(GstAudioChannelPosition)<
GST_AUDIO_CHANNEL_POSITION_FRONT_LEFT, GST_AUDIO_CHANNEL_POSITION_FRONT_RIGHT,
GST_AUDIO_CHANNEL_POSITION_REAR_LEFT, GST_AUDIO_CHANNEL_POSITION_REAR_RIGHT,
GST_AUDIO_CHANNEL_POSITION_FRONT_CENTER, GST_AUDIO_CHANNEL_POSITION_LFE,
GST_AUDIO_CHANNEL_POSITION_SIDE_LEFT, GST_AUDIO_CHANNEL_POSITION_SIDE_RIGHT >
DEBUG (0x80870a0 - 306518:47:33.080000000)            alsa(26646)
gstalsa.c(1063):gst_alsa_link: found format S16_LE
INFO  (0x80870a0 - 306518:47:33.080060000)            alsa(26646)
gstalsa.c(1449):gst_alsa_probe_hw_params: Probing format: S16_LE 11024Hz, 1 channels
WARN  (0x80870a0 - 306518:47:33.081960000)            alsa(26646)
gstalsa.c(1491):gst_alsa_probe_hw_params:<alsasink0>
"snd_pcm_hw_params_set_period_size_near (this->handle, hw_params, &period_size,
0)": Argument invalide

** (totem:26646): WARNING **: could not link audio/x-raw-int,
endianness=(int)1234, width=(int)8, depth=(int)8, signed=(boolean)false,
rate=(int)11024, channels=(int)1
Comment 4 Stephane Loeuillet 2004-12-19 14:49:15 UTC
oh shit, better attach it, quite unreadable actually, sorry
Comment 5 Stephane Loeuillet 2004-12-19 14:50:14 UTC
Created attachment 35005 [details]
alsa error log with mvi33.avi file in totem
Comment 6 David Schleef 2004-12-19 20:35:17 UTC
Does 'gst-launch-0.8 sinesrc ! audio/x-raw-int, rate=8012 ! alsasink' work?
Comment 7 Stephane Loeuillet 2004-12-19 21:05:45 UTC
LC_ALL=C gst-launch-0.8 -v sinesrc ! audio/x-raw-int, rate=8012 ! alsasink
RUNNING pipeline ...
ERROR: pipeline doesn't want to play.

LC_ALL=C gst-launch-0.8 -v sinesrc ! audio/x-raw-int, rate=8000 ! alsasink
works
Comment 8 Stephane Loeuillet 2004-12-19 21:23:34 UTC
found working values : 8000/16000/24000/32000/48000, 11025/22050/44100
tested non working values : 8001, 8012, 11024, 22370, 44000, ....

all bad ones die with something like :

DEBUG (0x80508f0 - 306525:21:56.459241000)            alsa(22370)
gstalsa.c(1063):gst_alsa_link: found format S16_LE
INFO  (0x80508f0 - 306525:21:56.459393000)            alsa(22370)
gstalsa.c(1449):gst_alsa_probe_hw_params: Probing format: S16_LE 33075Hz, 1 channels
WARN  (0x80508f0 - 306525:21:56.467292000)            alsa(22370)
gstalsa.c(1491):gst_alsa_probe_hw_params:<alsasink0>
"snd_pcm_hw_params_set_period_size_near (this->handle, hw_params, &period_size,
0)": Invalid argument
Comment 9 Stephane Loeuillet 2004-12-19 22:01:57 UTC
in the snd_pcm_hardware_t structure, there are 2 things :
-----------------
rates field contains the bit-flags of supported rates (SNDRV_PCM_RATE_XXX). When
the chip supports continuous rates, pass CONTINUOUS bit additionally. The
pre-defined rate bits are provided only for typical rates. If your chip supports
unconventional rates, you need to add KNOT bit and set up the hardware
constraint manually (explained later).
-----------------
rate_min and rate_max define the minimal and maximal sample rate. This should
correspond somehow to rates bits
-----------------

so, once the device is selected, we know what sample rates are usable (and
certainly not rate_min => rate_max which looks like we do actually (in gstalsa.c)

i'll try do that hardware probing
Comment 10 David Schleef 2004-12-19 22:59:16 UTC
OMG, this will make alsa caps even _more_ complicated.
Comment 11 Stephane Loeuillet 2004-12-19 23:09:37 UTC
Created attachment 35026 [details]
HW sample rate probing for alsa

of course, it is a standalone simple command line app

./probe hw:0,0 p
  8000 supported
 11025 supported
 16000 supported
 22050 supported
 32000 supported
 44100 supported
 48000 supported

./probe hw:0,1 c
 48000 supported

it should now be integrated in the right place of
gst-plugins/gst/alsa/gstalsa.* to populate the caps
Comment 12 Benjamin Otte (Company) 2004-12-20 11:54:47 UTC
Uh, I don't like this.
What if my alsa device does support 12345 Hz?
Comment 13 Stephane Loeuillet 2004-12-20 23:11:31 UTC
Created attachment 35065 [details]
gst_alsa_rateprobe.tar.bz2

a completly rewritten version :
 - uses glib/gstreamer types
 - returns caps (GST_TYPE_INT_RANGE or GST_TYPE_LIST, depending on the device
capabilities)
 - returns RANGE if it detects a dummy/software device (plughw:X,Y ...)
 - returns LIST if it detects a real device
Comment 14 Stephane Loeuillet 2004-12-20 23:50:42 UTC
Company :

hw:0,0 c supports { 8000, 11025, 16000, 22050, 32000, 44100, 48000 }
hw:0,2 p supports { 48000 }
plughw:0,0 c supports [ 8000, 48000 ]

it's the best method i have found to know which sample rate an alsa device supports.

if anyone know a way to do better, i'm open to suggestions
Comment 15 Stephane Loeuillet 2004-12-21 00:03:07 UTC
Created attachment 35067 [details]
gst_alsa_rateprobe.tar.bz2

cleaned-up version :
 - remove unnecessary headers, gst_type_init, ...
 - gst-indent
 - build.sh and probe.pl now does test all hw:X,Y and plughw:X,Y devices
Comment 16 David Schleef 2004-12-21 01:50:00 UTC
My hardware supports any rate.
Comment 17 Ronald Bultje 2004-12-21 08:45:35 UTC
look at how oss does this... OSS probes ranges, doesn't it?
Comment 18 David Schleef 2004-12-21 21:25:00 UTC
osssink probes sample rates, but gives up and assumes a range if there are at
least 20 rates are supported.  The algorithm assures that those 20 rates test a
wide range of spacings between potential fixed rates, so it would be one very
weird sound card that passes the test but only allows fixed rates.  One would
have hoped alsa supports explicitly probing ranges, since it's a very basic need.
Comment 19 Stephane Loeuillet 2005-01-10 17:11:45 UTC
fixed in CVS