commit | cae0b21c5816b4e3991b27f59d6faaf180db50e1 | [log] [tgz] |
---|---|---|
author | Kevin Lubick <kjlubick@google.com> | Tue Sep 12 18:33:10 2023 +0000 |
committer | Kevin Lubick <kjlubick@google.com> | Tue Sep 12 18:33:45 2023 +0000 |
tree | 7eda31e16545ed12c062ab937b06e998ce5d146e | |
parent | 9f1c93593c79eeb86f94206c5e83bb4f7b9d77ca [diff] [blame] |
[base] Update GrDirectContext calls to use safer API In http://review.skia.org/750403 and http://review.skia.org/751523, Skia modified some GrDirectContext APIs to make them less error-prone in response to https://crbug.com/1475906. This updates part of Android to call those modified APIs. Change-Id: I164fcc735b3c36bf58de2f1ed9f277e90fc09325
diff --git a/libs/hwui/HardwareBitmapUploader.cpp b/libs/hwui/HardwareBitmapUploader.cpp index 19a1dfa..16de21d 100644 --- a/libs/hwui/HardwareBitmapUploader.cpp +++ b/libs/hwui/HardwareBitmapUploader.cpp
@@ -22,6 +22,7 @@ #include <GLES2/gl2ext.h> #include <GLES3/gl3.h> #include <GrDirectContext.h> +#include <GrTypes.h> #include <SkBitmap.h> #include <SkCanvas.h> #include <SkImage.h> @@ -265,7 +266,7 @@ sk_sp<SkImage> image = SkImages::TextureFromAHardwareBufferWithData(mGrContext.get(), bitmap.pixmap(), ahb); - mGrContext->submit(true); + mGrContext->submit(GrSyncCpu::kYes); uploadSucceeded = (image.get() != nullptr); });