code: public boolean swapBuffers() {
          boolean result = false;
          synchronized(NativeScreen.framebufferSwapLock) {
              result = egl.eglSwapBuffers(eglDisplay, eglSurface);
  // TODO this shouldn't happen. In case the surface is invalid, we need to have recreated it before this method is called
              if (!result) {
                  createSurface();
                  result = egl.eglSwapBuffers(eglDisplay, eglSurface);
              }
          }
          return result;
  
      }
docs: Copy the contents of the GL backbuffer to the screen
  
  @return success or failure