I have an application that uses OpenGL on a GLSurfaceView. The problem
is that the initial load takes quite a while processing textures and
getting things ready.
What i want to do is have a simple PNG displayed (with a slight
animation) while the GLSurfaceView is getting ready. As soon as it’s
ready to render, i would like to tear down the splash screen.
What is the right way to do this? I’ve tried ViewFlipper, ViewSwitcher
and a bunch of other things to switch between my R.layout.main view
and my GLSurfaceView but i can’t seem to get it right.
Any ideas?
Step #1: Make your
GLSurfaceViewbeandroid:visibility="invisible"in your layout XMLStep #2: Put that
GLSurfaceViewinside of aFrameLayoutStep #3: Add an
ImageViewas another child of the sameFrameLayoutStep #4: When the
GLSurfaceViewis ready, make theImageViewbe invisible and make theGLSurfaceViewbe visible