From b61aef839f6256889b54144cff790fdfde430cda Mon Sep 17 00:00:00 2001 From: Jan Schmidt Date: Mon, 11 Dec 2006 21:21:16 +0000 Subject: [PATCH] sys/sunaudio/gstsunaudiosink.c: Ignore the buffer_time the sound device reports. Turns out it is sometimes completely... Original commit message from CVS: * sys/sunaudio/gstsunaudiosink.c: (gst_sunaudiosink_prepare): Ignore the buffer_time the sound device reports. Turns out it is sometimes completely bogus and we're better off without it. --- ChangeLog | 6 ++++++ sys/sunaudio/gstsunaudiosink.c | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/ChangeLog b/ChangeLog index 104c7e3ea5..2b8ec3250c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2006-12-08 Jan Schmidt + + * sys/sunaudio/gstsunaudiosink.c: (gst_sunaudiosink_prepare): + Ignore the buffer_time the sound device reports. Turns out it is + sometimes completely bogus and we're better off without it. + 2006-12-11 Tim-Philipp Müller * gst/matroska/matroska-demux.c: (gst_matroska_demux_add_stream), diff --git a/sys/sunaudio/gstsunaudiosink.c b/sys/sunaudio/gstsunaudiosink.c index 6e52de90ad..a189905a58 100644 --- a/sys/sunaudio/gstsunaudiosink.c +++ b/sys/sunaudio/gstsunaudiosink.c @@ -406,8 +406,14 @@ gst_sunaudiosink_prepare (GstAudioSink * asink, GstRingBufferSpec * spec) strerror (errno))); return FALSE; } +#if 0 + /* We don't actually use the buffer_size from the sound device, because + * it seems it's just bogus sometimes */ sunaudiosink->segtotal = spec->segtotal = ainfo.play.buffer_size / spec->segsize; +#else + sunaudiosink->segtotal = spec->segtotal; +#endif sunaudiosink->segtotal_samples = spec->segtotal * spec->segsize / spec->bytes_per_sample;