# fedyfausto/jetstudio architecture

> Architecture diagram of the GitHub repository fedyfausto/jetstudio, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-10). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/fedyfausto/jetstudio
- Repository: https://github.com/fedyfausto/jetstudio

## Overview

Jet Studio is a Godot-based 3D editor paired with a portable C++ runtime, Jet renderer, and JetScript language. Its main play workflow is to load a scene or exported package, run scripts and runtime systems, render frames, and present them through the desktop player or embedded firmware. The graph also preserves documented animation, physics, particles, and asset-import capabilities. Evidence is limited to the README and sampled/indexed files; editor UI implementation is not present in the supplied tree, and several runtime modules were not sampled.

Main entry points: [`runtime/runtime.cpp`](https://github.com/fedyfausto/jetstudio/blob/main/runtime/runtime.cpp) (Scene Runtime), [`native/jet_bridge.cpp`](https://github.com/fedyfausto/jetstudio/blob/main/native/jet_bridge.cpp) (Godot Bridge), [`firmware/src/main.cpp`](https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/main.cpp) (ESP32 Firmware), [`firmware_stm32/src/main.cpp`](https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/main.cpp) (STM32 Firmware)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_editor["Editor Bridge"]
  node_godot_editor["Godot Editor"]
  node_bridge["Godot Bridge<br/>[jet_bridge.cpp]"]
end

subgraph group_runtime["Game Runtime"]
  node_runtime_core["Scene Runtime<br/>[runtime.cpp]"]
  node_physics["2D/3D Physics<br/>[physics.cpp]"]
  node_particles["Particle System<br/>[particles.cpp]"]
  node_animation["Animation<br/>[animation.cpp]"]
  node_obj_import["OBJ Import<br/>[obj_import.cpp]"]
  node_texture["Texture Support<br/>[texture.cpp]"]
  node_tween["Tweening<br/>[tween.cpp]"]
  node_package["Package Export<br/>[pack.cpp]"]
end

subgraph group_scripting["JetScript"]
  node_script_host["Runtime Script Host<br/>[script_host.cpp]"]
  node_parser["JetScript Parser<br/>[js_parser.cpp]"]
  node_language["JetScript Runtime<br/>[js_vm.cpp]"]
end

subgraph group_targets["Playback Targets"]
  node_desktop["Desktop Player<br/>[main.cpp]"]
  node_esp_firmware["ESP32 Firmware<br/>[main.cpp]"]
  node_stm_firmware["STM32 Firmware<br/>[main.cpp]"]
  node_esp_scene["ESP32 Scene Data"]
  node_stm_scene["STM32 Scene Data"]
  node_esp_board["ESP32 Board Config"]
  node_stm_board["STM32 Board Config"]
  node_scanout["ESP32 Scanout<br/>[S3Scanout.hpp]"]
  node_hardware["Board Hardware Tools<br/>[hardware.py]"]
  node_serial["Serial Port<br/>[serial_port.cpp]"]
end

node_author(("Project Author"))

node_author -->|"authors projects"| node_godot_editor
node_godot_editor -->|"calls runtime bridge"| node_bridge
node_bridge -->|"loads and runs"| node_runtime_core
node_bridge -->|"imports models"| node_obj_import
node_desktop -->|"starts runtime"| node_runtime_core
node_esp_firmware -->|"starts runtime"| node_runtime_core
node_stm_firmware -->|"starts runtime"| node_runtime_core
node_esp_firmware -->|"reads scene data"| node_esp_scene
node_stm_firmware -->|"reads scene data"| node_stm_scene
node_esp_firmware -->|"uses board config"| node_esp_board
node_stm_firmware -->|"uses board config"| node_stm_board
node_esp_firmware -->|"uses scanout"| node_scanout
node_runtime_core -->|"uses physics"| node_physics
node_runtime_core -->|"uses script host"| node_script_host
node_runtime_core -->|"uses particles"| node_particles
node_script_host -->|"queries physics types"| node_physics
node_script_host -.->|"hosts scripts"| node_language
node_parser -.->|"parses scripts for"| node_language
node_runtime_core -.->|"supports animation"| node_animation
node_runtime_core -.->|"supports tweening"| node_tween
node_bridge -->|"exports packages"| node_package
node_hardware -.->|"supports board workflow"| node_esp_firmware
node_bridge -.->|"exposes serial"| node_serial

click node_bridge "https://github.com/fedyfausto/jetstudio/blob/main/native/jet_bridge.cpp"
click node_desktop "https://github.com/fedyfausto/jetstudio/blob/main/desktop/main.cpp"
click node_esp_firmware "https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/main.cpp"
click node_stm_firmware "https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/main.cpp"
click node_esp_scene "https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/generated_scene.hpp"
click node_stm_scene "https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/generated_scene.hpp"
click node_esp_board "https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/generated_board.hpp"
click node_stm_board "https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/generated_board.hpp"
click node_scanout "https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/S3Scanout.hpp"
click node_hardware "https://github.com/fedyfausto/jetstudio/blob/main/tools/hardware.py"
click node_runtime_core "https://github.com/fedyfausto/jetstudio/blob/main/runtime/runtime.cpp"
click node_physics "https://github.com/fedyfausto/jetstudio/blob/main/runtime/physics.cpp"
click node_particles "https://github.com/fedyfausto/jetstudio/blob/main/runtime/particles.cpp"
click node_animation "https://github.com/fedyfausto/jetstudio/blob/main/runtime/animation.cpp"
click node_obj_import "https://github.com/fedyfausto/jetstudio/blob/main/runtime/obj_import.cpp"
click node_texture "https://github.com/fedyfausto/jetstudio/blob/main/runtime/texture.cpp"
click node_tween "https://github.com/fedyfausto/jetstudio/blob/main/runtime/tween.cpp"
click node_package "https://github.com/fedyfausto/jetstudio/blob/main/runtime/pack.cpp"
click node_script_host "https://github.com/fedyfausto/jetstudio/blob/main/runtime/script_host.cpp"
click node_parser "https://github.com/fedyfausto/jetstudio/blob/main/runtime/script/js_parser.cpp"
click node_language "https://github.com/fedyfausto/jetstudio/blob/main/runtime/script/js_vm.cpp"
click node_serial "https://github.com/fedyfausto/jetstudio/blob/main/native/serial_port.cpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_godot_editor,node_bridge toneBlue
class node_runtime_core,node_physics,node_particles,node_animation,node_obj_import,node_texture,node_tween,node_package toneAmber
class node_script_host,node_parser,node_language toneMint
class node_desktop,node_esp_firmware,node_stm_firmware,node_esp_scene,node_stm_scene,node_esp_board,node_stm_board,node_scanout,node_hardware,node_serial toneRose
class node_author toneIndigo
```

## Components

### Editor Bridge

- **Godot Editor**
- [Godot Bridge](https://github.com/fedyfausto/jetstudio/blob/main/native/jet_bridge.cpp): `native/jet_bridge.cpp`

### Game Runtime

- [Scene Runtime](https://github.com/fedyfausto/jetstudio/blob/main/runtime/runtime.cpp): `runtime/runtime.cpp`
- [2D/3D Physics](https://github.com/fedyfausto/jetstudio/blob/main/runtime/physics.cpp): `runtime/physics.cpp`
- [Particle System](https://github.com/fedyfausto/jetstudio/blob/main/runtime/particles.cpp): `runtime/particles.cpp`
- [Animation](https://github.com/fedyfausto/jetstudio/blob/main/runtime/animation.cpp): `runtime/animation.cpp`
- [OBJ Import](https://github.com/fedyfausto/jetstudio/blob/main/runtime/obj_import.cpp): `runtime/obj_import.cpp`
- [Texture Support](https://github.com/fedyfausto/jetstudio/blob/main/runtime/texture.cpp): `runtime/texture.cpp`
- [Tweening](https://github.com/fedyfausto/jetstudio/blob/main/runtime/tween.cpp): `runtime/tween.cpp`
- [Package Export](https://github.com/fedyfausto/jetstudio/blob/main/runtime/pack.cpp): `runtime/pack.cpp`

### JetScript

- [Runtime Script Host](https://github.com/fedyfausto/jetstudio/blob/main/runtime/script_host.cpp): `runtime/script_host.cpp`
- [JetScript Parser](https://github.com/fedyfausto/jetstudio/blob/main/runtime/script/js_parser.cpp): `runtime/script/js_parser.cpp`
- [JetScript Runtime](https://github.com/fedyfausto/jetstudio/blob/main/runtime/script/js_vm.cpp): `runtime/script/js_vm.cpp`

### Playback Targets

- [Desktop Player](https://github.com/fedyfausto/jetstudio/blob/main/desktop/main.cpp): `desktop/main.cpp`
- [ESP32 Firmware](https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/main.cpp): `firmware/src/main.cpp`
- [STM32 Firmware](https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/main.cpp): `firmware_stm32/src/main.cpp`
- [ESP32 Scene Data](https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/generated_scene.hpp): `firmware/src/generated_scene.hpp`
- [STM32 Scene Data](https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/generated_scene.hpp): `firmware_stm32/src/generated_scene.hpp`
- [ESP32 Board Config](https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/generated_board.hpp): `firmware/src/generated_board.hpp`
- [STM32 Board Config](https://github.com/fedyfausto/jetstudio/blob/main/firmware_stm32/src/generated_board.hpp): `firmware_stm32/src/generated_board.hpp`
- [ESP32 Scanout](https://github.com/fedyfausto/jetstudio/blob/main/firmware/src/S3Scanout.hpp): `firmware/src/S3Scanout.hpp`
- [Board Hardware Tools](https://github.com/fedyfausto/jetstudio/blob/main/tools/hardware.py): `tools/hardware.py`
- [Serial Port](https://github.com/fedyfausto/jetstudio/blob/main/native/serial_port.cpp): `native/serial_port.cpp`

### Other components

- **Project Author**

## Connections

- Project Author → Godot Editor: authors projects
- Godot Editor → Godot Bridge: calls runtime bridge
- Godot Bridge → Scene Runtime: loads and runs (evidence: `native/jet_bridge.cpp`)
- Godot Bridge → OBJ Import: imports models (evidence: `native/jet_bridge.cpp`)
- Desktop Player → Scene Runtime: starts runtime (evidence: `desktop/main.cpp`)
- ESP32 Firmware → Scene Runtime: starts runtime (evidence: `firmware/src/main.cpp`)
- STM32 Firmware → Scene Runtime: starts runtime (evidence: `firmware_stm32/src/main.cpp`)
- ESP32 Firmware → ESP32 Scene Data: reads scene data (evidence: `firmware/src/main.cpp`)
- STM32 Firmware → STM32 Scene Data: reads scene data (evidence: `firmware_stm32/src/main.cpp`)
- ESP32 Firmware → ESP32 Board Config: uses board config (evidence: `firmware/src/main.cpp`)
- STM32 Firmware → STM32 Board Config: uses board config (evidence: `firmware_stm32/src/main.cpp`)
- ESP32 Firmware → ESP32 Scanout: uses scanout (evidence: `firmware/src/main.cpp`)
- Scene Runtime → 2D/3D Physics: uses physics (evidence: `runtime/runtime.cpp`)
- Scene Runtime → Runtime Script Host: uses script host (evidence: `runtime/runtime.cpp`)
- Scene Runtime → Particle System: uses particles (evidence: `runtime/runtime.cpp`)
- Runtime Script Host → 2D/3D Physics: queries physics types (evidence: `runtime/script_host.cpp`)
- Runtime Script Host → JetScript Runtime: hosts scripts
- JetScript Parser → JetScript Runtime: parses scripts for
- Scene Runtime → Animation: supports animation
- Scene Runtime → Tweening: supports tweening
- Godot Bridge → Package Export: exports packages
- Board Hardware Tools → ESP32 Firmware: supports board workflow
- Godot Bridge → Serial Port: exposes serial
