Interface implemented by each full-screen mode (Lobby, Game).
More...
#include <IScreen.hpp>
|
| virtual | ~IScreen ()=default |
| virtual SDL_AppResult | event (SDL_Event *event)=0 |
| | Handle an incoming SDL event.
|
| virtual SDL_AppResult | iterate ()=0 |
| | Update the screen state and render the next frame.
|
| virtual void | quit ()=0 |
| | Perform any necessary cleanup before the screen is destroyed.
|
| virtual void | shutdownAfterRenderer () |
| | Perform cleanup that must happen after the App-owned renderer shuts down.
|
Interface implemented by each full-screen mode (Lobby, Game).
App owns one active IScreen at a time and delegates SDL event processing, per-frame iteration, and shutdown to it.
◆ ~IScreen()
| virtual IScreen::~IScreen |
( |
| ) |
|
|
virtualdefault |
◆ event()
| virtual SDL_AppResult IScreen::event |
( |
SDL_Event * | event | ) |
|
|
pure virtual |
Handle an incoming SDL event.
- Parameters
-
| event | The SDL event to process. |
- Returns
- SDL_APP_CONTINUE to keep running, SDL_APP_FAILURE to exit.
Implemented in Game, Home, and Lobby.
◆ iterate()
| virtual SDL_AppResult IScreen::iterate |
( |
| ) |
|
|
pure virtual |
Update the screen state and render the next frame.
- Returns
- SDL_APP_CONTINUE to keep running, SDL_APP_FAILURE to exit.
Implemented in Game, Home, and Lobby.
◆ quit()
| virtual void IScreen::quit |
( |
| ) |
|
|
pure virtual |
Perform any necessary cleanup before the screen is destroyed.
Implemented in Game, Home, and Lobby.
◆ shutdownAfterRenderer()
| virtual void IScreen::shutdownAfterRenderer |
( |
| ) |
|
|
inlinevirtual |
Perform cleanup that must happen after the App-owned renderer shuts down.
Reimplemented in Game.
The documentation for this class was generated from the following file: