/** * Just the current frame in the display. */ void Engine::DrawFrame() { float fps; if (monitor_.Update(fps)) { UpdateFPS(fps); } renderer_.Update(monitor_.GetCurrentTime()); // Just fill the screen with a color. glClearColor(0.5f, 0.5f, 0.5f, 1.f); glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); renderer_.Render(); // Swap if (EGL_SUCCESS != gl_context_->Swap()) { UnloadResources(); LoadResources(); } }