summaryrefslogtreecommitdiffstats
path: root/stream
diff options
context:
space:
mode:
authorreimar <reimar@b3059339-0415-0410-9bf9-f77b7e298cf2>2011-06-04 10:27:45 +0000
committerUoti Urpala <uau@mplayer2.org>2011-07-06 09:32:27 +0300
commitc6e4eb9f4b7e8e588aebba07b055d81aea27c5fe (patch)
tree6cf47a50d73c25594bfe8307c463df3d8578e096 /stream
parent55def9cc1b8621c5f4e85cde9368b678e1f482a7 (diff)
downloadmpv-c6e4eb9f4b7e8e588aebba07b055d81aea27c5fe.tar.bz2
mpv-c6e4eb9f4b7e8e588aebba07b055d81aea27c5fe.tar.xz
stream_cdda: work around libcdparanoia caching issues
Constrain libcdparanoia's caching which badly breaks playback with -nocache (libcdparanoia requests a huge chunk at once, then lets the disk spin down while that is being played, leading to a pause when the disk needs to spin back up after the big chunk is finished). Switching to libcdio by default which does not have this ssue might be a better long-term solution though. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33557 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream')
-rw-r--r--stream/stream_cdda.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/stream/stream_cdda.c b/stream/stream_cdda.c
index e93c0465d8..53ac76cf25 100644
--- a/stream/stream_cdda.c
+++ b/stream/stream_cdda.c
@@ -420,6 +420,9 @@ static int open_cdda(stream_t *st,int m, void* opts, int* file_format) {
if(p->no_skip)
mode |= PARANOIA_MODE_NEVERSKIP;
#ifndef CONFIG_LIBCDIO
+ // HACK against libcdparanoia's stupid caching model that
+ // queues up a huge number of requests leading to stuttering
+ paranoia_cachemodel_size(priv->cdp, 24);
paranoia_modeset(cdd, mode);
if(p->search_overlap >= 0)