GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Kinetra-Lab/launcher/README.md at main · SMB-M87/Kinetra-Lab

Expand file tree

/

README.md

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
90 lines (66 loc) · 6.66 KB
/

README.md

Copy path

File metadata and controls

90 lines (66 loc) · 6.66 KB
Raw
Copy raw file
Download raw file
Outline
Edit and raw actions

Bundled launcher

The kinetra executable: one window with a menu from which Demo, Dotio and i4sim are started. It is a composition root. It decides which applications exist and how they start, and contains no menu, session or overlay mechanics of its own; those come from Kinetra.

Table of contents

  • Purpose and scope
  • Structure
  • How it works
  • Arguments
  • Changing this module
  • Tests

Parent guide · Project overview · Documentation index

Purpose and scope

The launcher lets a user try every Lab application without restarting, and gives the Lab one place that composes all three. Not here: application behavior (each application's session), the menu and the loop (kinetra::LaunchMenu, kinetra::run_launcher), and the shared Lab settings policy (labs/shared, described in launcher and overlays).

Structure

File Responsibility
include/launcher/applications.h Variant, Options, Lab's LauncherBindings, and the applications() and selection() declarations
src/applications.cpp Registrations, Demo scenarios, Dotio difficulties, camera resets and session factories
previews and EmbedPreviews.cmake Captured stills and their build-time embedding
src/main.cpp Arguments, the world seed and the call to kinetra::run_launcher

kinetra_sessions builds applications.cpp and links the three presentation libraries and Kinetra::Launcher. The kinetra executable uses it. The capture tool starts its sessions through the same registrations, so its screenshots show what the launcher starts.

How it works

stateDiagram-v2
    direction LR
    [*] --> Menu
    Menu --> Configuration: DEMO or DOTIO
    Configuration --> Menu: cancel
    Menu --> Running: I4SIM
    Configuration --> Running: confirm
    Running --> Menu: LAUNCHER, Escape or M on the i4sim blueprint screen
    Running --> Configuration: SCENARIOS or DIFFICULTY in the settings panel
    Configuration --> Menu: LAUNCHER or M
    Running --> [*]: Settings EXIT or window closed
    Menu --> [*]: EXIT or window closed
Loading

Takeaway: sessions leave through their own requests; the launcher binds no keys.

  1. main reads the arguments and takes the world seed from --seed, or draws a random one, and prints it, so --seed can start the same world again.
  2. launcher::applications(options) builds the registrations. Each factory resets the camera and creates a fresh session from the options.
  3. kinetra::run_launcher shows the menu, or starts --variant directly, and hosts one session at a time with launcher::bindings (no menu key, no Escape shutdown).

Moving the pointer or using the arrow keys on the application list updates the preview with a capture and a short description of the highlighted lab (screenshot). Demo scenarios and Dotio difficulties appear on their own pages after confirmation. The first button of Demo's and Dotio's settings panel, SCENARIOS or DIFFICULTY in place of LAUNCHER, returns to that page with the running choice selected (kinetra::SessionRequest::configurations); the page's LAUNCHER button, or M, returns to the application list.

Selecting an application always creates a new session, so returning to the menu discards the old run. A factory that throws reports the error and ends the program.

Arguments

Argument Accepted values
--variant demo, dotio, i4sim; omit for the menu
--difficulty easy, medium, hard for Dotio; default medium
--scenario terrain, gravity, maze, doorway, corridor, crossing, circle, bottleneck, chaos, fleet, swarm. Starts Demo directly. The default for --variant demo is terrain
--agents 0–300 initial agents in Demo's Terrain scenario. Default 48
--seed 0–4294967295, the world seed of every session the run starts, as with kinetra_dotio and kinetra_i4sim; omit for a random seed. The seed fixes the world, not the input
--frames 1–100000 rendered frames; omit for unlimited

Controls are in the Demo, Dotio and i4sim guides.

Changing this module

  • Add an application: add its value to Variant (menu order), a registration in applications(), and its presentation library to kinetra_sessions in CMakeLists.txt. Its session derives from kinetra_lab::Session, returns its settings overlay's request (with configurations, it passes kinetra::LeaveAction{label, SessionRequest::configurations} to its SettingsOverlay, as Demo does with SCENARIOS, so the panel's first button asks for its page), titles the window with the application's name and reports its state through status(). Extend kinetra_menu with the new name, and add its scenes to the capture tool.
  • Add an application option: add it to Options, parse it in main.cpp, and capture it in the factory. Configurations shown in the menu come from the application (as Dotio's difficulties do), not from the launcher.

To refresh a preview, pass the lab's preview scene (demo-preview, dotio-preview or i4sim-preview), launcher and ui-launcher to the capture script in one command. It embeds the new still before capturing the launcher.

Tests

CTest Covers Needs
kinetra_menu Registration order and previews, Demo scenarios, Dotio difficulties, defaults, and configuration picking at resized viewports Runtime build, no window
kinetra_graphics Every application through the real launcher sessions: settings toggles, pause and resume, debug gating, the Shift+Ctrl shortcut and debug-menu rows (RUNNING, layers, ZOOM, GHOST CAMERA), the FPS row, the settings panel's SCENARIOS, DIFFICULTY and EXIT requests KINETRA_TEST_GRAPHICS, an OpenGL context
kinetra_launcher:seed-* A negative, too large, textual or trailing-character --seed stops kinetra with Invalid seed before a window opens Runtime build, no window
kinetra_smoke:launcher* kinetra starts in the menu and with each --variant at seed 42, draws 120 frames and exits with 0; launcher-seed checks that --seed 4294967295 is the printed world seed KINETRA_TEST_GRAPHICS, an OpenGL context
ctest --preset dev -R '^kinetra_(menu|launcher):'
cmake --workflow --preset graphics
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.