summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2014-08-21 22:09:48 +0200
committerwm4 <wm4@nowhere>2014-08-21 22:45:58 +0200
commit218ace2b02e2f2a867c4b792d4a1ec03015d7294 (patch)
treef07f5b7b51c748f99d8095a73257056863b49576
parentf1e78306cb0efab153e2580b45759cdf3c1482f2 (diff)
downloadmpv-218ace2b02e2f2a867c4b792d4a1ec03015d7294.tar.bz2
mpv-218ace2b02e2f2a867c4b792d4a1ec03015d7294.tar.xz
audio: limit on low (and not high) buffer size
The original intention was probably to avoid unnecessarily high numbers of wakeups. Change it to wait at most 25% of buffer time instead of 75% until refilling. Might help with the dsound problems in issue #1024, but I don't know if success is guaranteed.
-rw-r--r--audio/out/push.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/audio/out/push.c b/audio/out/push.c
index c825310e01..f35c597100 100644
--- a/audio/out/push.c
+++ b/audio/out/push.c
@@ -281,7 +281,7 @@ static double ao_estimate_timeout(struct ao *ao)
if (timeout > 0.100)
timeout = MPMAX(timeout - 0.200, 0.100);
}
- return MPMAX(timeout, ao->device_buffer * 0.75 / ao->samplerate);
+ return MPMAX(timeout, ao->device_buffer * 0.25 / ao->samplerate);
}
static void *playthread(void *arg)