diff options
| author | Ana Krulec <akrulec@google.com> | 2020-12-14 14:28:22 -0800 |
|---|---|---|
| committer | Ana Krulec <akrulec@google.com> | 2020-12-15 16:19:13 -0800 |
| commit | f85b559a7f72c72c19167aa4fedec8e67cbd2268 (patch) | |
| tree | afb5647c013154c38c7e8f7d8f4b74a3c5ae718e /core/java/android/view/SurfaceControl.java | |
| parent | 70829412220d231e1dfffcac8b794086fdf67862 (diff) | |
Plumbing through GPU context priority
If the SF's RE priority is set to REALTIME, then SysUI set's it's
ThreadedRendererCompat priority to EGL_CONTEXT_PRIORITY_HIGH_IMG.
Test: Compile and observe logcat.
Bug: 168740533
Change-Id: Ib2fdac90c22b357d8b9f5c80c03a3d9c4e1a515d
Diffstat (limited to 'core/java/android/view/SurfaceControl.java')
| -rw-r--r-- | core/java/android/view/SurfaceControl.java | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/core/java/android/view/SurfaceControl.java b/core/java/android/view/SurfaceControl.java index 23de215eeefc..f642d7580d4d 100644 --- a/core/java/android/view/SurfaceControl.java +++ b/core/java/android/view/SurfaceControl.java @@ -232,6 +232,7 @@ public final class SurfaceControl implements Parcelable { long nativeSurfaceControl); private static native void nativeRemoveJankDataListener(long nativeListener); private static native long nativeCreateJankDataListenerWrapper(OnJankDataListener listener); + private static native int nativeGetGPUContextPriority(); @Nullable @GuardedBy("mLock") @@ -2438,7 +2439,15 @@ public final class SurfaceControl implements Parcelable { nativeRemoveJankDataListener(listener.mNativePtr.get()); } - /** + /** + * Return GPU Context priority that is set in SurfaceFlinger's Render Engine. + * @hide + */ + public static int getGPUContextPriority() { + return nativeGetGPUContextPriority(); + } + + /** * An atomic set of changes to a set of SurfaceControl. */ public static class Transaction implements Closeable, Parcelable { |
