Example usage for android.opengl GLES20 GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING

List of usage examples for android.opengl GLES20 GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING

Introduction

In this page you can find the example usage for android.opengl GLES20 GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING.

Prototype

int GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING

To view the source code for android.opengl GLES20 GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING.

Click Source Link

Usage

From source file:Main.java

public static void checkGLError(String msg) {
    int error = GLES20.glGetError();
    if (error != GLES20.GL_NO_ERROR) {
        String str = msg + ": glError 0x" + Integer.toHexString(error);
        Log.e(TAG, str);//from w  w w  . j av  a  2  s .c  om
        int values[] = new int[2];
        GLES20.glGetIntegerv(GLES20.GL_ARRAY_BUFFER_BINDING, values, 0);
        GLES20.glGetIntegerv(GLES20.GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING, values, 1);
        Log.e(TAG, "Current bound array buffer: " + values[0]);
        Log.e(TAG, "Current bound vertex attrib: " + values[1]);
        throw new RuntimeException(msg);
    }
}