diff options
author | Julian <MyFakeAcc.4@googlemail.com> | 2016-07-30 02:24:51 +0900 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2017-10-09 20:40:31 +0200 |
commit | 97c1cd66580ef191b8968ee2b35c47bd8d2a3fff (patch) | |
tree | f03286af7d9915910580c7819200c88ee4a50907 /player/lua/stats.lua | |
parent | 3f4fd36aa8810b3893a7989278552ceeda103315 (diff) | |
download | mpv-97c1cd66580ef191b8968ee2b35c47bd8d2a3fff.tar.bz2 mpv-97c1cd66580ef191b8968ee2b35c47bd8d2a3fff.tar.xz |
stats: fix bug introduced in earlier commit
Commit 76387aba26574d0d96af688cf11d10bd165171f7 broke the script in case
of timing_total=true.
Diffstat (limited to 'player/lua/stats.lua')
-rw-r--r-- | player/lua/stats.lua | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/player/lua/stats.lua b/player/lua/stats.lua index 938efa33ce..a9dc8dbba0 100644 --- a/player/lua/stats.lua +++ b/player/lua/stats.lua @@ -185,8 +185,7 @@ local function append_perfdata(s) local last_s = vo_p["render-last"] + vo_p["present-last"] + vo_p["upload-last"] local avg_s = vo_p["render-avg"] + vo_p["present-avg"] + vo_p["upload-avg"] - --local peak_s = vo_p["render-peak"] + vo_p["present-peak"] + vo_p["upload-peak"] - local peak_s = -math.huge + local peak_s = vo_p["render-peak"] + vo_p["present-peak"] + vo_p["upload-peak"] -- highlight i with a red border when t exceeds the time for one frame -- or yellow when it exceeds a given threshold @@ -239,13 +238,13 @@ local function append_perfdata(s) local f = "%s%s%s{\\fn%s}%s / %s / %s{\\fn%s}%s%s" s[#s+1] = format(f, o.nl, o.indent, o.indent, o.font_mono, hl(vo_p["render-last"], last_s), hl(vo_p["render-avg"], avg_s), - hl(vo_p["render-peak"], peak_s), o.font, o.prefix_sep, rsuffix) + hl(vo_p["render-peak"], -math.huge), o.font, o.prefix_sep, rsuffix) s[#s+1] = format(f, o.nl, o.indent, o.indent, o.font_mono, hl(vo_p["present-last"], last_s), hl(vo_p["present-avg"], avg_s), - hl(vo_p["present-peak"], peak_s), o.font, o.prefix_sep, psuffix) + hl(vo_p["present-peak"], -math.huge), o.font, o.prefix_sep, psuffix) s[#s+1] = format(f, o.nl, o.indent, o.indent, o.font_mono, hl(vo_p["upload-last"], last_s), hl(vo_p["upload-avg"], avg_s), - hl(vo_p["upload-peak"], peak_s), o.font, o.prefix_sep, usuffix) + hl(vo_p["upload-peak"], -math.huge), o.font, o.prefix_sep, usuffix) if o.timing_total then s[#s+1] = format(f, o.nl, o.indent, o.indent, o.font_mono, hl(last_s, last_s), hl(avg_s, avg_s), |