Separate ImageDecoder JNI from actual work
Bug: 135133301
Test: CtsGraphicsTestCases ImageDecoderTest
Make the native ImageDecoder a class, with methods that do the bulk of
the work that was previously done in JNI. This will allow the
forthcoming NDK API (AImageDecoder) to share the same code for decoding.
Move enums into implementation file, as no other code needs them.
Make computeAllocationSize a public static method on hwui/Bitmap, for
use by ImageDecoder.
Change-Id: I4e4dae338a951761614aed42ca2cc157e3d526dd
diff --git a/libs/hwui/Android.bp b/libs/hwui/Android.bp
index f670cf9..d945fc4 100644
--- a/libs/hwui/Android.bp
+++ b/libs/hwui/Android.bp
@@ -176,6 +176,7 @@
"hwui/AnimatedImageThread.cpp",
"hwui/Bitmap.cpp",
"hwui/Canvas.cpp",
+ "hwui/ImageDecoder.cpp",
"hwui/MinikinSkia.cpp",
"hwui/MinikinUtils.cpp",
"hwui/PaintImpl.cpp",