aboutsummaryrefslogtreecommitdiffhomepage
path: root/include/core/SkTime.h
diff options
context:
space:
mode:
authorGravatar mtklein <mtklein@chromium.org>2015-10-22 13:33:21 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2015-10-22 13:33:22 -0700
commita1840d50e29fd95e4df2d1168fe54c34c2a5c30c (patch)
tree77e89242b2f3ae8ecf71da647fc651b3b124012f /include/core/SkTime.h
parentc9b5f8b1522e72449d704d30ed6aee4fc6211ee8 (diff)
SkTime::GetNSecs()
- Move high-precision wall timers from tools/timer to SkTime. - Implement SkTime::GetMSecs() in terms of SkTime::GetNSecs(). - Delete unused tools/timer code. I have no idea what's going on there in src/animator. I don't intend to investigate. BUG=skia: Committed: https://skia.googlesource.com/skia/+/70084cbc16ee8162649f2601377feb6e49de0217 CQ_EXTRA_TRYBOTS=client.skia.compile:Build-Ubuntu-GCC-x86_64-Debug-CrOS_Link-Trybot Review URL: https://codereview.chromium.org/1422513003
Diffstat (limited to 'include/core/SkTime.h')
-rw-r--r--include/core/SkTime.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/core/SkTime.h b/include/core/SkTime.h
index a8656347aa..2cfe3efcb4 100644
--- a/include/core/SkTime.h
+++ b/include/core/SkTime.h
@@ -34,7 +34,8 @@ public:
};
static void GetDateTime(DateTime*);
- static SkMSec GetMSecs();
+ static SkMSec GetMSecs() { return (SkMSec)(GetNSecs() * 1e-6); }
+ static double GetNSecs();
};
#if defined(SK_DEBUG) && defined(SK_BUILD_FOR_WIN32)