diff options
author | 2018-03-22 12:36:22 -0400 | |
---|---|---|
committer | 2018-03-22 12:36:22 -0400 | |
commit | 5388f79a4518b132b304c5b475f28f49fbb88232 (patch) | |
tree | 225eab436590c50f97903bef9a650479997b19e0 | |
parent | f344b3ead51d3ac96c60223cbc9a4a0bc7c61576 (diff) |
Disable Bitmap density scaling to Picture
Bug: 76144110
Test: I95165583649a1df86782d3684f7bf9bcd8dab7bd
This matches the behavior of DisplayListCanvas. Not scaling means that
we can draw a Bitmap to a Picture, and then play that back in HW mode
and see the same result.
Change-Id: I7421431bad0531112e06ab5c14814b6b6f1591d9
-rw-r--r-- | graphics/java/android/graphics/Picture.java | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/graphics/java/android/graphics/Picture.java b/graphics/java/android/graphics/Picture.java index 9ac94d895a37..d01ff6fb8373 100644 --- a/graphics/java/android/graphics/Picture.java +++ b/graphics/java/android/graphics/Picture.java @@ -209,6 +209,8 @@ public class Picture { public PictureCanvas(Picture pict, long nativeCanvas) { super(nativeCanvas); mPicture = pict; + // Disable bitmap density scaling. This matches DisplayListCanvas. + mDensity = 0; } @Override |