From b63f6005c1a72758a976984b1b00de4b1e66418b Mon Sep 17 00:00:00 2001 From: Brian Osman Date: Tue, 24 Jul 2018 18:01:53 -0400 Subject: Add 'u' to zoom stats display on high DPI devices Still need to connect this to ImGui, but this is already useful Bug: skia: Change-Id: I925c7a9d6236cb2d865d45d6a68a5709bf2e3df7 Reviewed-on: https://skia-review.googlesource.com/143158 Reviewed-by: Jim Van Verth Commit-Queue: Brian Osman --- tools/viewer/StatsLayer.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'tools/viewer/StatsLayer.h') diff --git a/tools/viewer/StatsLayer.h b/tools/viewer/StatsLayer.h index a99bd43a99..b888517e2c 100644 --- a/tools/viewer/StatsLayer.h +++ b/tools/viewer/StatsLayer.h @@ -26,6 +26,8 @@ public: void onPaint(SkCanvas* canvas) override; + void setDisplayScale(float scale) { fDisplayScale = scale; } + private: static const int kMeasurementCount = 1 << 6; // should be power of 2 for fast mod struct TimerData { @@ -38,6 +40,7 @@ private: int fCurrentMeasurement; double fCumulativeMeasurementTime; int fCumulativeMeasurementCount; + float fDisplayScale; }; #endif -- cgit v1.2.3