summaryrefslogtreecommitdiffstats
path: root/cfg-mplayer.h
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2012-09-18 14:29:22 +0200
committerwm4 <wm4@nowhere>2012-09-23 14:56:30 +0200
commitaf14474879f088031154ce441341fc56352b7341 (patch)
tree513b6f3d9cdefe4a69026fda6ede9419bce644a2 /cfg-mplayer.h
parent5a617d02d95d59fbf06e865489d75fdc1ce46203 (diff)
downloadmpv-af14474879f088031154ce441341fc56352b7341.tar.bz2
mpv-af14474879f088031154ce441341fc56352b7341.tar.xz
options: make cache option always per-file
When playing a network stream, the cache is automatically enabled. We don't want the cache to stay enabled when playback ends. (For example, the next file to be played could be a local file, and even if that is relatively contrieved, we want to do the right thing.) Introduced the flag M_OPT_LOCAL to force an option to be always file local. This allows enabling the old mplayer semantics on a per option basis.
Diffstat (limited to 'cfg-mplayer.h')
-rw-r--r--cfg-mplayer.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/cfg-mplayer.h b/cfg-mplayer.h
index 304c60f194..ed3fef7304 100644
--- a/cfg-mplayer.h
+++ b/cfg-mplayer.h
@@ -338,7 +338,8 @@ const m_option_t common_opts[] = {
// ------------------------- stream options --------------------
#ifdef CONFIG_STREAM_CACHE
- OPT_INTRANGE("cache", stream_cache_size, 0, 32, 0x7fffffff, OPTDEF_INT(-1)),
+ OPT_INTRANGE("cache", stream_cache_size, M_OPT_LOCAL, 32, 0x7fffffff,
+ OPTDEF_INT(-1)),
OPT_FLAG_CONSTANTS("no-cache", stream_cache_size, 0, -1, 0),
OPT_FLOATRANGE("cache-min", stream_cache_min_percent, 0, 0, 99),