Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(9)

Unified Diff: tools/SkCodecTools.h

Issue 1344993003: Add nanobench tests for BitmapRegionDecoder (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gyp/visualbench.gyp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/SkCodecTools.h
diff --git a/tools/SkCodecTools.h b/tools/SkCodecTools.h
new file mode 100644
index 0000000000000000000000000000000000000000..097915b5d719711c37559f860791ca3b50936dd7
--- /dev/null
+++ b/tools/SkCodecTools.h
@@ -0,0 +1,15 @@
+/*
+ * Copyright 2015 Google Inc.
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+#ifndef SkCodecTools_DEFINED
+#define SkCodecTools_DEFINED
+
+inline float get_scale_from_sample_size(uint32_t sampleSize) {
+ return 1.0f / (float) sampleSize;
+}
+
+#endif // SkCodecTools_DEFINED
« no previous file with comments | « gyp/visualbench.gyp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698