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

Unified Diff: ui/gfx/half_float.h

Issue 2648043002: Create FP16 LUTs when needed (Closed)
Patch Set: mark all floats as floats (not doubles) Created 3 years, 11 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 | « ui/gfx/BUILD.gn ('k') | ui/gfx/half_float.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/half_float.h
diff --git a/ui/gfx/half_float.h b/ui/gfx/half_float.h
new file mode 100644
index 0000000000000000000000000000000000000000..788607f2d1fa17160e5b712bfc2d2702f2b8150f
--- /dev/null
+++ b/ui/gfx/half_float.h
@@ -0,0 +1,22 @@
+// Copyright (c) 2017 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef UI_GFX_COLOR_HALF_FLOAT_H_
+#define UI_GFX_COLOR_HALF_FLOAT_H_
+
+#include <stdint.h>
+#include <stdlib.h>
+
+#include "ui/gfx/gfx_export.h"
+
+namespace gfx {
+
+typedef uint16_t HalfFloat;
+
+// Floats are expected to be within +/- 65535.0;
+GFX_EXPORT void FloatToHalfFloat(const float* input,
+ HalfFloat* output,
+ size_t num);
+};
+#endif
« no previous file with comments | « ui/gfx/BUILD.gn ('k') | ui/gfx/half_float.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698