Draw the logo when app loads, until the first SDL_Flip(), also fixed small bug in menu
This commit is contained in:
@@ -595,6 +595,8 @@ public class GLSurfaceView_SDL extends SurfaceView implements SurfaceHolder.Call
|
||||
public void setSwapBuffersCallback( SwapBuffersCallback c ) {
|
||||
mSwapBuffersCallback = c;
|
||||
}
|
||||
|
||||
public abstract void DrawLogo(GL10 gl);
|
||||
|
||||
private SwapBuffersCallback mSwapBuffersCallback = null;
|
||||
}
|
||||
@@ -904,7 +906,7 @@ public class GLSurfaceView_SDL extends SurfaceView implements SurfaceHolder.Call
|
||||
mNeedStart = true;
|
||||
mSizeChanged = true;
|
||||
SwapBuffers();
|
||||
DrawLogo();
|
||||
mRenderer.DrawLogo(mGL);
|
||||
SwapBuffers();
|
||||
|
||||
mRenderer.onDrawFrame(mGL);
|
||||
@@ -1113,16 +1115,6 @@ public class GLSurfaceView_SDL extends SurfaceView implements SurfaceHolder.Call
|
||||
return null;
|
||||
}
|
||||
|
||||
private void DrawLogo() {
|
||||
// TODO: draw some logo instead of making screen non-black
|
||||
/*
|
||||
mGL.glClearColor(0.0f, 0.5f, 0.7f, 1.0f);
|
||||
mGL.glClear(mGL.GL_COLOR_BUFFER_BIT | mGL.GL_DEPTH_BUFFER_BIT);
|
||||
mGL.glFlush();
|
||||
mGL.glClearColor(0.0f, 0.0f, 0.0f, 1.0f);
|
||||
*/
|
||||
}
|
||||
|
||||
private boolean mDone;
|
||||
private boolean mPaused;
|
||||
private boolean mHasSurface;
|
||||
|
||||
Reference in New Issue
Block a user