You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Aug 8, 2023. It is now read-only.
Copy file name to clipboardexpand all lines: platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/maps/renderer/textureview/TextureViewRenderThread.java
+29-12
Original file line number
Diff line number
Diff line change
@@ -213,6 +213,12 @@ public void run() {
213
213
break;
214
214
}
215
215
216
+
// (re-)Initialize EGL Surface if needed
217
+
if (eglHolder.eglSurface == EGL10.EGL_NO_SURFACE) {
218
+
recreateSurface = true;
219
+
break;
220
+
}
221
+
216
222
// Check if the size has changed
217
223
if (sizeChanged) {
218
224
recreateSurface = true;
@@ -247,7 +253,14 @@ public void run() {
247
253
// Initialize EGL
248
254
if (initializeEGL) {
249
255
eglHolder.prepare();
250
-
eglHolder.createSurface();
256
+
if (!eglHolder.createSurface()) {
257
+
synchronized (lock) {
258
+
// Cleanup the surface if one could not be created
0 commit comments