Java – Android OPenGL+ XML integration

Android OPenGL+ XML integration… here is a solution to the problem.

Android OPenGL+ XML integration

I’m making a media player app in android where part of my screen has an animation made in OpenGL (Android/JAVA, of course)… So my screen consists of two parts:
1) The left side contains all widgets (using XML).
2) The right side consists of animations made by OpenGL.

I was able to make GUIs (XML parts) and animations (OpenGL).
Can I integrate the GUI of XML file authoring with animations (made using GLSurfaceview)?

Solution

APIDemos SurfaceViewOverlay example is an answer to my query…. In the xml file, I have to create a GLSurfaceView tag like this:

            <android.opengl.GLSurfaceView android:id="@+id/glsurfaceview"
            android:layout_width="match_parent"
            android:layout_height="match_parent" />

Related Problems and Solutions