Hi everybody, First thing I'm a novice about coding, I learn by myself 9 month ago so I'm really not strong ^^. I have a game with google analytic installed and I get a lot of error report related to [EGL] like this : . [EGL] Unable to create context!: EGL_BAD_CONTEXT: An EGLContext argument does not name a valid EGL rendering context. . [EGL] Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindowType argument does not refer to a valid native window. . [EGL] Unable to acquire context: EGL_BAD_SURFACE: An EGLSurface argument does not name a valid surface (window, pixel buffer or pixmap) configured for GL rendering. . [EGL] Unable to find a configuration matching minimum spec! . [EGL] Failed to create window surface: EGL_BAD_NATIVE_WINDOW: A NativeWindowType argument does not refer to a valid native window. . [EGL] Unable to acquire context: EGL_BAD_ALLOC: EGL failed to allocate resources for the requested operation. . [EGL] Failed to create window surface: EGL_BAD_ALLOC: EGL failed to allocate resources for the requested operation. . [EGL] Unable to acquire context: EGL_BAD_ACCESS: EGL cannot access a requested resource (for example a context is bound in another thread). . [EGL] eglDestroySurface(m_EGLDisplay, m_EGLSurface): EGL_BAD_PARAMETER: One or more argument values are invalid. . [EGL] eglDestroySurface(m_EGLDisplay, m_EGLSurface): EGL_BAD_SURFACE: An EGLSurface argument does not name a valid surface (window, pixel buffer or pixmap) configured for GL rendering. . [EGL] Unable to release context: EGL_BAD_ALLOC: EGL failed to allocate resources for the requested operation. I use Unity 5.0.2 with NGui and some othe plugin (social,ads and unibill). I don't even know how to recreate these problem, and of course of to solve them. I just know these problem comes from : . Samsung Galaxy Pocket Plus (S5301, GT-S5301L , GT-S5301B, GT-S5303B . Samsung Galaxy Tab 3 lite . Samsung Galaxy Y Plus . and more and more ^^ I use an automatic compression for all my texture, may be the problem come frome here, should I use ETC instead ? Thanks in advance for your patience
Same problem as I am facing. I have tried to start a new blank project but got the same problem. So, the reason should not be related to plugin.
I only got that one too : [EGL] Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindow Type argument does not refer to a valid native window. Still have no idea from where it could come ???
Getting on multiple Android devices, including at least the following: Samsung GT-P5100 Samsung GT-P5110 Samsung GT-P5210 Samsung GT-P5220 Quanta Gigaset QV830 Judging from the logs, it seems to happen when leaving the app on the background and switching back. Using Unity 5.1.3p2, forced OpenGL ES 2.0. Left a bug report (725668) but couldn't really post a repro.
I'm also getting: [EGL] Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindowType argument does not refer to a valid native window. Here's a break down of devices it's occurring on and OS's (if it helps).
@jun.yambao0312 No, I don't think it depends on the brand, nor the Android version. We also see quite some of these types of errors in our Unity Android projects. I am not sure if this actually causes a crash, or that it is merely an error log and the user's experience is not affected in a (really) bad manner. Maybe a Unity dev/support can elaborate on this, since it pretty much clutters error reporting, but the cause is rather unclear, as is reproducibility.
Not entirely sure if it's a certain brand or OS, but I dumped the data, in case there was some sort of pattern. Every little helps!
We are also seeing a fairly substantial number of these being reported in our crash tracking tool and interestingly they seems to be a lot of overlap with the devices listed by poolts:
Up +1 E/Unity: [EGL] Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindowType (Filename: ./Runtime/GfxDevice/egl/WindowContextEGL.cpp Line: 205) Note 4
I got the same error when I upgraded to Unity 5.3.2 (from 4.3.4) and tried to deploy my previously working game to my Nexus 7: Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindowType (Filename: ./Runtime/GfxDevice/egl/WindowContextEGL.cpp Line: 205) In my case I found the error was slightly misleading, and seemed to be caused by an earlier error: a call to Shader.Find("Standard") was returning null. It appears that Unity's stripping seemed to be working differently and had stripped out the standard shader (since I never directly referenced it). Hope that helps someone.
https://issuetracker.unity3d.com/is...kground-egl-bad-native-window-on-some-devices This seems to now be fixed in Unity 5.4.1
We were getting a similar error log using Unity 5.3.5p2. 06-20 17:01:25.949: E/Unity(6687): [EGL] Unable to acquire context: EGL_BAD_MATCH: Arguments are inconsistent (for example, a valid context requires buffers not supplied by a valid surface). We don't get this error with Unity 5.4.1. The problem is the beta breaks several other things so upgrading at this point is not an option for us since our project is live Did upgrading to 5.4.1 fix the issue for the rest of you? YAY! I just tested in Unity 5.3.5p4 and the crash is gone!
Getting the error: [EGL] Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindowType argument does not refer to a valid native window. with Unity 5.5.0f3 Does anyone still getting this issue?
@_creatio_ I'm on Unity 5.5.2f1 and we have a sligtly different error that was reported in our log files. Seems like this is still happening, there is no callstack so it`s ready hard to see what's wrong. [EGL] Failed to create window surface: EGL_BAD_ALLOC: EGL failed to allocate resources for the requested operation. Edit: Occurs on the SAMSUNG SM-G920W8 running Android 6.0.1
On our devices we get the EGL error when we do the following: - Open app - Send app to background by pressing home-button - Re-open app by taping on the app-icon - ... see a nice black screen When we return to the app by using the task manager everything works fine. It happens on Unity 5.6.3 and up. Here's the error log: 11-10 11:55:24.726: W/Adreno-EGL(18850): <qeglDrvAPI_eglMakeCurrent:3083>: EGL_BAD_ACCESS 11-10 11:55:24.726: E/libEGL(18850): eglMakeCurrent:836 error 3002 (EGL_BAD_ACCESS) 11-10 11:55:24.727: E/Unity(18850): [EGL] Unable to acquire context: EGL_BAD_ACCESS: EGL cannot access a requested resource (for example a context is bound in another thread). 11-10 11:55:24.727: E/Unity(18850): 11-10 11:55:24.727: E/Unity(18850): (Filename: ./Runtime/GfxDevice/egl/WindowContextEGL.cpp Line: 267)
I'm getting a similar error log in Unity 2017.3.0f3 E/libEGL: eglMakeCurrent:831 error 3002 (EGL_BAD_ACCESS) E/Unity: [EGL] Unable to acquire context: EGL_BAD_ACCESS: EGL cannot access a requested resource (for example a context is bound in another thread). (Filename: /Users/builduser/buildslave/unity/build/Runtime/GfxDevice/egl/WindowContextEGL.cpp Line: 267) I export my project to Android Studio,and it worked well. I use" Intent intent=new Intent(UnityPlayer.currentActivity,TencentOpenActivity.class); UnityPlayer.currentActivity.startActivity(intent);" to open my activity ,and then finish this activity.It also worked well. However,I use" Tencent.login(TencentOpenActivity.this,"all",listener);"to open another app. When the app back to my application,I finish TencentOpenActivity.Then,I got a black Screen and the error log.
I am having the same problem. I am trying to get it to work in 2018 now ------------- Didn't work ------------ Seems like 2017.2 works too atleast for me!
Had a kinda similar problem, after a week of debugging I noticed that it was the instantiation of graphic objects (MeshRenderers and such) while the app is in background, I believe the bug occurs when Unity tries to send information to the graphics processor and the OS already killed the surface / buffer or whatever (Im not the most technical dev) but its just a theory. Anyway, I made a flag when the app is loading and its in background and resume the instantiation of objects when the app goes foreground again. In our case this was happening when our users grew tired of loading times (or ads) and went to other apps in the meantime Hope this saves someone's time
Well it definitely save my time. 2018.4.5f1 and most of advertising plugins update to newest version and suddenly I starter to face this issue. I'm creating object pools during first scene for various models (that had textures, shaders, particles, etc.), so now I postponed instantiation of these models until moment when main scene is loaded. So, your theory has good roots.
Hi, did anyone find the reason for the critical error: [EGL] Unable to acquire context: EGL_BAD_NATIVE_WINDOW: A NativeWindowType argument does not refer to a valid native window.
I am also running into this issue on some Android based mobile VR devices; specifically the Pico Neo 2. Any more insight into what causes this?
Got the same error on Samsung S6, after which application just froze forever. Any info on how can I debug this issue? Unity 2019.4.5f
I got this problem in Unity 2020.3.3f1 (LTS). I created a simple project and imported google AdMob, I found this bug make GPU overload after 5 6 frames after something happened. I guess when admob show interstitial ads, have a job from CPU send to GPU while app in background mode and that job make GPU run a error command.=> GPU time slow down and completely stuck after few frames.
This issue is reported on Android Versions < 10.0. I didn't find this issue critical because its not effecting the gameplay.
Getting this error on various Android devices: Unity 2021.3.10f1. "Graphics Jobs (Experimental)" is not enabled. Devices: motorola moto e(6) plus Android OS 9 / API-28 (PTBS29.401-58-8/58-8) motorola moto e(7) Android OS 10 / API-29 (QOFS30.569-83-11/45005) Xiaomi M2006C3LG Android OS 10 / API-29 (QP1A.190711.020/V12.0.20.0.QCDMIXM)