summaryrefslogtreecommitdiff
path: root/libs/hwui/HardwareBitmapUploader.h
diff options
context:
space:
mode:
authorLeon Scroggins III <scroggo@google.com>2019-01-31 08:42:23 -0500
committerLeon Scroggins III <scroggo@google.com>2019-01-31 10:38:26 -0500
commitee3bfe7681d44da520ec646c3e500ccecaaab228 (patch)
tree344bd055b515b3cddc3a4cb8c085820ea793864d /libs/hwui/HardwareBitmapUploader.h
parent81973983b02c8cd7289b45afa3cc794eae0833a7 (diff)
Only decode to F16 if HARDWARE supports it
Bug: 123301974 Test: Infeasible If a Bitmap is going to be decoded to F16 and then converted to HARDWARE, only decode to F16 if HARDWARE supports it. Previously, if we discovered after the decode that HARDWARE did not support F16, we had to copy back to 8888 before the upload. Change-Id: I3ceb9d053ba134bb96cfb9d638e54ac652e5db29
Diffstat (limited to 'libs/hwui/HardwareBitmapUploader.h')
-rw-r--r--libs/hwui/HardwareBitmapUploader.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/libs/hwui/HardwareBitmapUploader.h b/libs/hwui/HardwareBitmapUploader.h
index 40f2b0c7873c..6f41e6db4e32 100644
--- a/libs/hwui/HardwareBitmapUploader.h
+++ b/libs/hwui/HardwareBitmapUploader.h
@@ -20,10 +20,12 @@
namespace android::uirenderer {
-class HardwareBitmapUploader {
+class ANDROID_API HardwareBitmapUploader {
public:
static sk_sp<Bitmap> allocateHardwareBitmap(const SkBitmap& sourceBitmap);
static void terminate();
+
+ static bool hasFP16Support();
};
} // namespace android::uirenderer