summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-03-10 01:28:27 +0100
committerwm4 <wm4@nowhere>2014-03-10 01:28:39 +0100
commitb3f9d3750b8e1e627008758181aa98a6c788e7cd (patch)
treeba3b1bbb506b2261a95ec260b1e24ab4760b16fe
parent2e10f536db95648a33f0db903d86ccb58ca7ec00 (diff)
downloadmpv-b3f9d3750b8e1e627008758181aa98a6c788e7cd.tar.bz2
mpv-b3f9d3750b8e1e627008758181aa98a6c788e7cd.tar.xz
ao_alsa: reduce default buffer size
In general, we don't need to have a large hw audio buffer size anymore, because we can quickly fill it from the soft buffer. Note that this probably doesn't change much anyway. On my system (dmix enabled), the buffer size is only 170ms, and ALSA won't give more. Even when using a hardware device the buffer size seems to be limited to 341ms.
-rw-r--r--audio/out/ao_alsa.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/audio/out/ao_alsa.c b/audio/out/ao_alsa.c
index 5a62fbfa94..9b53a3af2f 100644
--- a/audio/out/ao_alsa.c
+++ b/audio/out/ao_alsa.c
@@ -67,7 +67,7 @@ struct priv {
int cfg_resample;
};
-#define BUFFER_TIME 500000 // 0.5 s
+#define BUFFER_TIME 250000 // 250ms
#define FRAGCOUNT 16
#define CHECK_ALSA_ERROR(message) \