![]() |
vkmEngine 1.0.0
A C++ game engine · vkmengine.com
|
The engine's entry point into rendering. More...
#include <render_system.h>
Public Member Functions | |
| void | update (FrameContext &ctx) override |
| Run one frame of rendering. | |
| void | setBackend (std::unique_ptr< RenderBackend > backend, WindowManager &window) |
| Bring a backend up against the window and draw through it. | |
| void | releaseUploadedPixels (bool release) |
| Free each texture's CPU pixels once the backend holds them. | |
| BackendInfo | backendInfo () const |
| Identity of the active backend, for status displays. | |
| uint32_t | maxAnisotropy () const |
| The active backend's anisotropic-filtering ceiling. | |
| RenderBackend * | backend () const |
| The active backend, or nullptr before setBackend(). | |
| Public Member Functions inherited from Vkm::Engine::System | |
| virtual bool | isReplayed () const |
| Whether this system may be re-run over a tick that already happened. | |
| virtual void | init (FrameContext &ctx) |
| Called once after all systems are registered, before the first update. | |
| virtual void | shutdown () |
| Called once on engine shutdown. | |
| virtual void | fixedUpdate (FrameContext &ctx) |
| Execute this system at the fixed simulation rate. | |
The engine's entry point into rendering.
Runs after Visibility, whose product it draws. Builds the RenderView each frame and hands it to the backend it owns; nothing here is API-specific.
|
overridevirtual |
Run one frame of rendering.
A no-op with no backend. Writes any screenshot requested via WindowManager::saveScreenshot.
| ctx | The frame: its scene, Visibility product and window. |
Reimplemented from Vkm::Engine::System.
| void Vkm::Engine::RenderSystem::setBackend | ( | std::unique_ptr< RenderBackend > | backend, |
| WindowManager & | window ) |
Bring a backend up against the window and draw through it.
Called once, at startup, with the window's API context current. Throws std::runtime_error when init fails, so the host exits rather than run a black window.
| backend | The backend to install. |
| window | The window it draws into. |
|
inline |
Free each texture's CPU pixels once the backend holds them.
For a host that never reads pixels after upload (a cooking host keeps them). After each frame, textures the backend holdsPixels for are released; params stay.
| release | Whether to release them. |
|
inline |
Identity of the active backend, for status displays.
|
inline |
The active backend's anisotropic-filtering ceiling.
|
inline |
The active backend, or nullptr before setBackend().