Erasmus
Erasmus

Reputation: 427

Android AndEngine problems: java.lang.IllegalArgumentException: No EGLConfig Found

Good evening!

I have been tinkering around with the AndEngine for game development in Android. I tried to run a Tower of Hanoi game application that uses the AndEngine, but the aformentioned error keeps running when I run it in the emulator. Here is the LogCat:

09-05 21:34:00.948: D/dalvikvm(633): No JNI_OnLoad found in   /data/data/com.tutorial.towerofhanoi/lib/libandengine.so 0x4101f730, skipping init
09-05 21:34:01.017: D/AndEngine(633): TowerOfHanoiActivity.onResume @(Thread: 'main')
09-05 21:34:01.067: I/dalvikvm(633): threadid=3: reacting to signal 3
09-05 21:34:01.137: I/dalvikvm(633): Wrote stack traces to '/data/anr/traces.txt'
09-05 21:34:01.207: D/libEGL(633): Emulator without GPU support detected. Fallback to software renderer.
09-05 21:34:01.207: D/libEGL(633): loaded /system/lib/egl/libGLES_android.so
09-05 21:34:01.238: W/dalvikvm(633): threadid=12: thread exiting with uncaught exception (group=0x409c01f8)
09-05 21:34:01.297: E/AndroidRuntime(633): FATAL EXCEPTION: GLThread 85
09-05 21:34:01.297: E/AndroidRuntime(633): java.lang.IllegalArgumentException: No EGLConfig found!
09-05 21:34:01.297: E/AndroidRuntime(633):  at org.andengine.opengl.view.ConfigChooser.chooseConfig(ConfigChooser.java:183)
09-05 21:34:01.297: E/AndroidRuntime(633):  at org.andengine.opengl.view.ConfigChooser.chooseConfig(ConfigChooser.java:157)
09-05 21:34:01.297: E/AndroidRuntime(633):  at android.opengl.GLSurfaceView$EglHelper.start(GLSurfaceView.java:1009)
09-05 21:34:01.297: E/AndroidRuntime(633):  at android.opengl.GLSurfaceView$GLThread.guardedRun(GLSurfaceView.java:1362)
09-05 21:34:01.297: E/AndroidRuntime(633):  at android.opengl.GLSurfaceView$GLThread.run(GLSurfaceView.java:1216)
09-05 21:34:01.309: D/gralloc_goldfish(633): Emulator without GPU emulation detected.
09-05 21:34:01.497: D/AndEngine(633): TowerOfHanoiActivity.onPause @(Thread: 'main')
09-05 21:34:03.867: I/Process(633): Sending signal. PID: 633 SIG: 9

The line of code affected by the error is at the AndEngine library itself, particularly this line:

            throw new IllegalArgumentException("No " + EGLConfig.class.getSimpleName() + " found!");

The screenshot shows the target I am building. It's API15 Android 4.0.3

enter image description here

How do I remedy this?

Upvotes: 3

Views: 3469

Answers (3)

tpbapp
tpbapp

Reputation: 2506

You need to enable the emulator GPU.

To do this in Eclipse go to Window > AVD Manager select your AVD and click "Edit...", check the "Use Host GPU" box, then save and restart your AVD.

Upvotes: 0

user2095816
user2095816

Reputation: 31

I had problem like this. My solution (need editing AVD):

  1. Enable "Use Host GPU"
  2. I changed CPU/ABI to "Intel Atom (x86)"
  3. I changed Target from API Level 17 to API Level 15 (Android 4.0.3)

And it works!!!

Upvotes: 0

jmroyalty
jmroyalty

Reputation: 2527

I think the problem is with this line

09-05 21:34:01.207: D/libEGL(633): Emulator without GPU support detected. Fallback to software renderer.

recreate or edit your emulator and be sure that under the hardware list you have

GPU Emulation set to Yes

Upvotes: 3

Related Questions