Expand description
Components for creating a desktop application that renders interactive all_is_cubes
content.
§Warning: Unstable! Dubiously designed!
This is not a good general-purpose library. It is primarily used
by the all-is-cubes binary target in this package; it currently only exists as a library
so that additional development tools can reuse the same UI code. Use at your own risk.
Documentation is lacking.
Modules§
- logging
- Logging. And terminal progress bars. And their cooperation.
- record
- Headless output of images, video, or export data formats.
- terminal
- Rendering as styled terminal text.
- winit
- Glue between
all_is_cubes,winit, andwinit-compatible renderers.
Structs§
- Desktop
Session - Wraps a basic
Sessionto add functionality that is common within all-is-cubes-desktop’s scope of supported usage (such as loading a universe from disk). - Executor
- Implementation of
all_is_cubes::util::Executorfor use with asmolexecutor, used byall-is-cubes-desktop. - Inner
Main Params - Ad-hoc struct of arguments to
inner_mainthat can be constructed before choosing an event loop type. - Settings
Args clap::Argsargument group struct for args that affect what settings are used.- Universe
Task - An async task that constructs a
Universethat will belong to aDesktopSession, delivered viaInnerMainParams.
Enums§
- Clock
Source - Defines the clock for time passing in the simulation managed by a
DesktopSession. - Universe
Source - Source of the universe to create/load.
Functions§
- choose_
graphical_ window_ size - Choose a window size (in terms of viewport size) when the user did not request one.
- headless_
main_ loop - Main loop function that does nothing but run the simulation.
Suitable for passing to
inner_main()if integration with another event loop is not needed. - inner_
main - Given a
DesktopSessionand an event loop type already decided, run the remainder of main operations. - load_
config - Load preferences/settings/config files from a platform-appropriate read/write location.
Type Aliases§
- Session
- Our concrete session type.