public void draw(boolean sync){
synchronized (mRenderLock) {
    if (!mDrawPending) {
      mEglHandler.post(mRenderTask);
      mDrawPending=true;
      if (sync) {
        try {
          mRenderLock.wait();
        }
 catch (        InterruptedException ex) {
          Log.v(TAG,"RenderLock.wait() interrupted");
        }
      }
    }
  }
}

public void draw ( boolean sync ) { synchronized ( mRenderLock ) { if ( ! mDrawPending ) { mEglHandler . post ( mRenderTask ) ; mDrawPending = true ; if ( sync ) { try { mRenderLock . wait ( ) ; } catch ( InterruptedException ex ) { Log . v ( TAG , "RenderLock.wait() interrupted" ) ; } } } } }
posts a render request to the gl thread .
