Loading core/java/android/os/GraphicsEnvironment.java +10 −0 Original line number Diff line number Diff line Loading @@ -94,6 +94,8 @@ public class GraphicsEnvironment { private static final int VULKAN_1_0 = 0x00400000; private static final int VULKAN_1_1 = 0x00401000; private static final int VULKAN_1_2 = 0x00402000; private static final int VULKAN_1_3 = 0x00403000; // Values for UPDATABLE_DRIVER_ALL_APPS // 0: Default (Invalid values fallback to default as well) Loading Loading @@ -213,6 +215,14 @@ public class GraphicsEnvironment { private int getVulkanVersion(PackageManager pm) { // PackageManager doesn't have an API to retrieve the version of a specific feature, and we // need to avoid retrieving all system features here and looping through them. if (pm.hasSystemFeature(PackageManager.FEATURE_VULKAN_HARDWARE_VERSION, VULKAN_1_3)) { return VULKAN_1_3; } if (pm.hasSystemFeature(PackageManager.FEATURE_VULKAN_HARDWARE_VERSION, VULKAN_1_2)) { return VULKAN_1_2; } if (pm.hasSystemFeature(PackageManager.FEATURE_VULKAN_HARDWARE_VERSION, VULKAN_1_1)) { return VULKAN_1_1; } Loading Loading
core/java/android/os/GraphicsEnvironment.java +10 −0 Original line number Diff line number Diff line Loading @@ -94,6 +94,8 @@ public class GraphicsEnvironment { private static final int VULKAN_1_0 = 0x00400000; private static final int VULKAN_1_1 = 0x00401000; private static final int VULKAN_1_2 = 0x00402000; private static final int VULKAN_1_3 = 0x00403000; // Values for UPDATABLE_DRIVER_ALL_APPS // 0: Default (Invalid values fallback to default as well) Loading Loading @@ -213,6 +215,14 @@ public class GraphicsEnvironment { private int getVulkanVersion(PackageManager pm) { // PackageManager doesn't have an API to retrieve the version of a specific feature, and we // need to avoid retrieving all system features here and looping through them. if (pm.hasSystemFeature(PackageManager.FEATURE_VULKAN_HARDWARE_VERSION, VULKAN_1_3)) { return VULKAN_1_3; } if (pm.hasSystemFeature(PackageManager.FEATURE_VULKAN_HARDWARE_VERSION, VULKAN_1_2)) { return VULKAN_1_2; } if (pm.hasSystemFeature(PackageManager.FEATURE_VULKAN_HARDWARE_VERSION, VULKAN_1_1)) { return VULKAN_1_1; } Loading