Skip to content

Commit

Permalink
#1299: expose the damage fps
Browse files Browse the repository at this point in the history
git-svn-id: https://xpra.org/svn/Xpra/trunk@13689 3bb7dfac-3a0b-4e04-842a-767bc560f471
  • Loading branch information
totaam committed Sep 13, 2016
1 parent 751c556 commit 38d1232
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions src/xpra/server/window/window_source.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,6 +389,13 @@ def get_info(self):
"rgb_formats" : self.rgb_formats,
#"icons" : self.icons_encoding_options,
})
now = time.time()
cutoff = now-5
lde = [x for x in self.statistics.last_damage_events if x[0]>=cutoff]
dfps = 0
if lde:
dfps = len(lde) // 5
info["damage.fps"] = dfps
if self.pixel_format:
info["pixel-format"] = self.pixel_format
idata = self.window_icon_data
Expand Down

0 comments on commit 38d1232

Please sign in to comment.