Crate all_is_cubes_desktop

Crate all_is_cubes_desktop 

Source
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, and winit-compatible renderers.

Structs§

DesktopSession
Wraps a basic Session to 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::Executor for use with a smol executor, used by all-is-cubes-desktop.
InnerMainParams
Ad-hoc struct of arguments to inner_main that can be constructed before choosing an event loop type.
SettingsArgs
clap::Args argument group struct for args that affect what settings are used.
UniverseTask
An async task that constructs a Universe that will belong to a DesktopSession, delivered via InnerMainParams.

Enums§

ClockSource
Defines the clock for time passing in the simulation managed by a DesktopSession.
UniverseSource
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 DesktopSession and 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.