Loading services/core/java/com/android/server/wm/WindowManagerService.java +3 −4 Original line number Diff line number Diff line Loading @@ -6380,10 +6380,9 @@ public class WindowManagerService extends IWindowManager.Stub } } // Copy the screenshot bitmap to another buffer so that the gralloc backed // bitmap will not have a long lifetime. Gralloc memory can be pinned or // duplicated and might have a higher cost than a skia backed buffer. Bitmap ret = bm.copy(bm.getConfig(),true); // Create a copy of the screenshot that is immutable and backed in ashmem. // This greatly reduces the overhead of passing the bitmap between processes. Bitmap ret = bm.createAshmemBitmap(); bm.recycle(); return ret; } Loading Loading
services/core/java/com/android/server/wm/WindowManagerService.java +3 −4 Original line number Diff line number Diff line Loading @@ -6380,10 +6380,9 @@ public class WindowManagerService extends IWindowManager.Stub } } // Copy the screenshot bitmap to another buffer so that the gralloc backed // bitmap will not have a long lifetime. Gralloc memory can be pinned or // duplicated and might have a higher cost than a skia backed buffer. Bitmap ret = bm.copy(bm.getConfig(),true); // Create a copy of the screenshot that is immutable and backed in ashmem. // This greatly reduces the overhead of passing the bitmap between processes. Bitmap ret = bm.createAshmemBitmap(); bm.recycle(); return ret; } Loading