glGetShaderInfoLog returns empty string (android)

前端 未结 3 873
闹比i
闹比i 2020-12-18 00:26

I am modifying the version of the android version of the 2d texture example from OpenGl ES2.0 programming guide to change the fragment shader. this is written in pure Java a

3条回答
  •  一个人的身影
    2020-12-18 01:09

    You're suffering from a bug. I worked around by using the old GL ES 2.0 bindings to get a functioning glGetShaderInfoLog. Like this:

    import com.badlogic.gdx.backends.android.AndroidGL20;
    ...
    AndroidGL20 gl2 = new AndroidGL20();
    Log.e(TAG, gl2.glGetShaderInfoLog(shader));
    

    I still use the standard GLES20 wrapper library for everything else, so this was simple to drop into my codebase. The two wrappers apparently can coexist without any problems.

提交回复
热议问题