Loading opengl/libs/EGL/Loader.cpp +21 −24 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ #include <android-base/properties.h> #include <android/dlext.h> #include <cutils/properties.h> #include <dirent.h> #include <dlfcn.h> #include <graphicsenv/GraphicsEnv.h> Loading Loading @@ -236,13 +237,7 @@ void* Loader::open(egl_connection_t* cnx) LOG_ALWAYS_FATAL("couldn't find an OpenGL ES implementation from %s", android::GraphicsEnv::getInstance().getDriverPath().c_str()); } // Finally, try to load system driver. If ANGLE is the system driver // (i.e. we are forcing the legacy system driver instead of ANGLE), use // the driver suffix that was passed down from above. if (shouldForceLegacyDriver) { std::string suffix = android::GraphicsEnv::getInstance().getLegacySuffix(); hnd = attempt_to_load_system_driver(cnx, suffix.c_str(), true); } else { // Finally, try to load system driver. // Start by searching for the library name appended by the system // properties of the GLES userspace driver in both locations. // i.e.: Loading @@ -261,7 +256,6 @@ void* Loader::open(egl_connection_t* cnx) } } } } if (!hnd) { // Can't find graphics driver by appending system properties, now search for the exact name Loading @@ -272,7 +266,10 @@ void* Loader::open(egl_connection_t* cnx) hnd = attempt_to_load_system_driver(cnx, nullptr, true); } if (!hnd && !failToLoadFromDriverSuffixProperty) { if (!hnd && !failToLoadFromDriverSuffixProperty && property_get_int32("ro.vendor.api_level", 0) < __ANDROID_API_U__) { // Still can't find the graphics drivers with the exact name. This time try to use wildcard // matching if the device is launched before Android 14. hnd = attempt_to_load_system_driver(cnx, nullptr, false); } Loading Loading
opengl/libs/EGL/Loader.cpp +21 −24 Original line number Diff line number Diff line Loading @@ -21,6 +21,7 @@ #include <android-base/properties.h> #include <android/dlext.h> #include <cutils/properties.h> #include <dirent.h> #include <dlfcn.h> #include <graphicsenv/GraphicsEnv.h> Loading Loading @@ -236,13 +237,7 @@ void* Loader::open(egl_connection_t* cnx) LOG_ALWAYS_FATAL("couldn't find an OpenGL ES implementation from %s", android::GraphicsEnv::getInstance().getDriverPath().c_str()); } // Finally, try to load system driver. If ANGLE is the system driver // (i.e. we are forcing the legacy system driver instead of ANGLE), use // the driver suffix that was passed down from above. if (shouldForceLegacyDriver) { std::string suffix = android::GraphicsEnv::getInstance().getLegacySuffix(); hnd = attempt_to_load_system_driver(cnx, suffix.c_str(), true); } else { // Finally, try to load system driver. // Start by searching for the library name appended by the system // properties of the GLES userspace driver in both locations. // i.e.: Loading @@ -261,7 +256,6 @@ void* Loader::open(egl_connection_t* cnx) } } } } if (!hnd) { // Can't find graphics driver by appending system properties, now search for the exact name Loading @@ -272,7 +266,10 @@ void* Loader::open(egl_connection_t* cnx) hnd = attempt_to_load_system_driver(cnx, nullptr, true); } if (!hnd && !failToLoadFromDriverSuffixProperty) { if (!hnd && !failToLoadFromDriverSuffixProperty && property_get_int32("ro.vendor.api_level", 0) < __ANDROID_API_U__) { // Still can't find the graphics drivers with the exact name. This time try to use wildcard // matching if the device is launched before Android 14. hnd = attempt_to_load_system_driver(cnx, nullptr, false); } Loading