Module crayon::application
[−]
[src]
A unified application model across all target platforms.
Application
An application needs to run on all types of esoteric host platforms. To hide trivial
platform-specific details, we offers a convenient trait Application
facade which
defined methods, that will be called in a pre-determined order every frame.
The most intuitive and simple setup function could be something like:
struct Window { ... } impl Application for Window { ... } fn main() { let mut engine = Engine::new(); let window = Window::new(&mut engine).unwrap(); engine.run(window).unrwap(); }
Engine
Engine
mentioned above is the most fundamental module in crayon. It binds various
essential systems in a central place, and responsible for running the main loop.
Re-exports
pub use self::time::TimeSystem; |
pub use self::settings::Settings; |
pub use self::context::Context; |
Modules
context |
The context of systems that could be accessed from multi-thread environments. |
event |
Responsible for converting window messages to input state and internal events. |
settings |
Functions for loading game settings. |
time |
Timing and stepping system. |
Structs
Engine |
|
FrameInfo |
The collected information during last frame. |
Traits
Application |
|
Type Definitions
Result |