# martindew/featherengine architecture

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

- Interactive diagram: https://gitdiagram.com/martindew/featherengine
- Repository: https://github.com/martindew/featherengine

## Overview

Feather is an early-stage C++ game engine: the README describes an ECS-based engine, while sampled code shows a default runtime loop that indexes project resources, initializes a world, advances simulation, and updates rendering. The tree also exposes resource loading, reflection, rendering, and ECS-related subsystems. Edges are limited to relationships explicit in the sampled runtime excerpt or source index; many implementation links remain unverified because their source was not excerpted.

Main entry points: [`main/default_engine.cpp`](https://github.com/martindew/featherengine/blob/master/main/default_engine.cpp) (Default Engine), [`tools/codegen/modifier_api.py`](https://github.com/martindew/featherengine/blob/master/tools/codegen/modifier_api.py) (Modifier API), [`tools/codegen/generate_reflection.py`](https://github.com/martindew/featherengine/blob/master/tools/codegen/generate_reflection.py) (Reflection Generator), [`tools/codegen/extensions/ecs.py`](https://github.com/martindew/featherengine/blob/master/tools/codegen/extensions/ecs.py) (ECS Modifiers)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_runtime["Engine Runtime"]
  node_default_engine["Default Engine<br/>[default_engine.cpp]"]
  node_engine_state["Engine State<br/>[engine.cpp]"]
  node_engine_settings["Engine Settings"]
  node_window["Display Window<br/>[window.cpp]"]
  node_display["Display Server<br/>[display_server.cpp]"]
end

subgraph group_world["World and ECS"]
  node_world_sim["World Simulation<br/>[world_sim.cpp]"]
  node_simulation["Simulation<br/>[simulation.cpp]"]
  node_scene_components["Scene Components<br/>[scene.cpp]"]
  node_ecs_module["ECS Module<br/>[ecs_module.cpp]"]
  node_world_modules["World Modules"]
end

subgraph group_render["Rendering"]
  node_renderer["Rendering Server"]
  node_render_scene["Render Scene<br/>[render_scene.cpp]"]
  node_vex_renderer["VEX Renderer<br/>[vex_renderer.cpp]"]
end

subgraph group_assets["Resources"]
  node_resource_loader["Resource Loader"]
  node_resource_formats["Format Loaders"]
  node_mesh_resource["Mesh Resource<br/>[mesh.cpp]"]
  node_texture_loader["Texture Loader"]
  node_material_loader["Material Loader"]
  node_extension_loader["Extension Loader"]
end

subgraph group_reflection["Reflection"]
  node_class_db["Class Database<br/>[class_db.cpp]"]
  node_variant["Variant Values<br/>[variant.cpp]"]
  node_reflection_generator["Reflection Generator"]
  node_modifier_api["Modifier API<br/>[modifier_api.py]"]
  node_ecs_modifiers["ECS Modifiers<br/>[ecs.py]"]
  node_core_modifiers["Core Modifiers<br/>[core_modifiers.py]"]
end

node_user(("Engine User"))

node_user -.->|"starts"| node_default_engine
node_default_engine -->|"indexes project"| node_resource_loader
node_default_engine -->|"initializes and updates"| node_world_sim
node_default_engine -->|"polls updates"| node_window
node_default_engine -->|"initializes and updates"| node_renderer
node_reflection_generator -->|"uses API"| node_modifier_api
node_ecs_modifiers -->|"implements"| node_modifier_api
node_core_modifiers -->|"implements"| node_modifier_api

click node_default_engine "https://github.com/martindew/featherengine/blob/master/main/default_engine.cpp"
click node_engine_state "https://github.com/martindew/featherengine/blob/master/core/engine.cpp"
click node_engine_settings "https://github.com/martindew/featherengine/blob/master/core/engine_settings.cpp"
click node_window "https://github.com/martindew/featherengine/blob/master/core/window.cpp"
click node_display "https://github.com/martindew/featherengine/blob/master/core/display_server.cpp"
click node_world_sim "https://github.com/martindew/featherengine/blob/master/world/world_sim.cpp"
click node_simulation "https://github.com/martindew/featherengine/blob/master/world/simulation.cpp"
click node_scene_components "https://github.com/martindew/featherengine/blob/master/world/components/scene.cpp"
click node_ecs_module "https://github.com/martindew/featherengine/blob/master/world/ecs_module.cpp"
click node_world_modules "https://github.com/martindew/featherengine/blob/master/world/rendering_world_module.cpp"
click node_renderer "https://github.com/martindew/featherengine/blob/master/rendering/rendering_server.cpp"
click node_render_scene "https://github.com/martindew/featherengine/blob/master/rendering/render_scene.cpp"
click node_vex_renderer "https://github.com/martindew/featherengine/blob/master/modules/vex_renderer/vex_renderer.cpp"
click node_resource_loader "https://github.com/martindew/featherengine/blob/master/resources/resource_loader.cpp"
click node_resource_formats "https://github.com/martindew/featherengine/blob/master/resources/resource_format_loader.cpp"
click node_mesh_resource "https://github.com/martindew/featherengine/blob/master/resources/mesh.cpp"
click node_texture_loader "https://github.com/martindew/featherengine/blob/master/resources/texture_format_loader.cpp"
click node_material_loader "https://github.com/martindew/featherengine/blob/master/resources/material_format_loader.cpp"
click node_extension_loader "https://github.com/martindew/featherengine/blob/master/resources/extension_format_loader.cpp"
click node_class_db "https://github.com/martindew/featherengine/blob/master/reflection/class_db.cpp"
click node_variant "https://github.com/martindew/featherengine/blob/master/reflection/variant.cpp"
click node_reflection_generator "https://github.com/martindew/featherengine/blob/master/tools/codegen/generate_reflection.py"
click node_modifier_api "https://github.com/martindew/featherengine/blob/master/tools/codegen/modifier_api.py"
click node_ecs_modifiers "https://github.com/martindew/featherengine/blob/master/tools/codegen/extensions/ecs.py"
click node_core_modifiers "https://github.com/martindew/featherengine/blob/master/tools/codegen/extensions/core_modifiers.py"

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_default_engine,node_engine_state,node_engine_settings,node_window,node_display,node_user toneBlue
class node_world_sim,node_simulation,node_scene_components,node_ecs_module,node_world_modules toneAmber
class node_renderer,node_render_scene,node_vex_renderer toneMint
class node_resource_loader,node_resource_formats,node_mesh_resource,node_texture_loader,node_material_loader,node_extension_loader toneRose
class node_class_db,node_variant,node_reflection_generator,node_modifier_api,node_ecs_modifiers,node_core_modifiers toneIndigo
```

## Components

### Engine Runtime

- [Default Engine](https://github.com/martindew/featherengine/blob/master/main/default_engine.cpp): `main/default_engine.cpp`
- [Engine State](https://github.com/martindew/featherengine/blob/master/core/engine.cpp): `core/engine.cpp`
- [Engine Settings](https://github.com/martindew/featherengine/blob/master/core/engine_settings.cpp): `core/engine_settings.cpp`
- [Display Window](https://github.com/martindew/featherengine/blob/master/core/window.cpp): `core/window.cpp`
- [Display Server](https://github.com/martindew/featherengine/blob/master/core/display_server.cpp): `core/display_server.cpp`

### World and ECS

- [World Simulation](https://github.com/martindew/featherengine/blob/master/world/world_sim.cpp): `world/world_sim.cpp`
- [Simulation](https://github.com/martindew/featherengine/blob/master/world/simulation.cpp): `world/simulation.cpp`
- [Scene Components](https://github.com/martindew/featherengine/blob/master/world/components/scene.cpp): `world/components/scene.cpp`
- [ECS Module](https://github.com/martindew/featherengine/blob/master/world/ecs_module.cpp): `world/ecs_module.cpp`
- [World Modules](https://github.com/martindew/featherengine/blob/master/world/rendering_world_module.cpp): `world/rendering_world_module.cpp`

### Rendering

- [Rendering Server](https://github.com/martindew/featherengine/blob/master/rendering/rendering_server.cpp): `rendering/rendering_server.cpp`
- [Render Scene](https://github.com/martindew/featherengine/blob/master/rendering/render_scene.cpp): `rendering/render_scene.cpp`
- [VEX Renderer](https://github.com/martindew/featherengine/blob/master/modules/vex_renderer/vex_renderer.cpp): `modules/vex_renderer/vex_renderer.cpp`

### Resources

- [Resource Loader](https://github.com/martindew/featherengine/blob/master/resources/resource_loader.cpp): `resources/resource_loader.cpp`
- [Format Loaders](https://github.com/martindew/featherengine/blob/master/resources/resource_format_loader.cpp): `resources/resource_format_loader.cpp`
- [Mesh Resource](https://github.com/martindew/featherengine/blob/master/resources/mesh.cpp): `resources/mesh.cpp`
- [Texture Loader](https://github.com/martindew/featherengine/blob/master/resources/texture_format_loader.cpp): `resources/texture_format_loader.cpp`
- [Material Loader](https://github.com/martindew/featherengine/blob/master/resources/material_format_loader.cpp): `resources/material_format_loader.cpp`
- [Extension Loader](https://github.com/martindew/featherengine/blob/master/resources/extension_format_loader.cpp): `resources/extension_format_loader.cpp`

### Reflection

- [Class Database](https://github.com/martindew/featherengine/blob/master/reflection/class_db.cpp): `reflection/class_db.cpp`
- [Variant Values](https://github.com/martindew/featherengine/blob/master/reflection/variant.cpp): `reflection/variant.cpp`
- [Reflection Generator](https://github.com/martindew/featherengine/blob/master/tools/codegen/generate_reflection.py): `tools/codegen/generate_reflection.py`
- [Modifier API](https://github.com/martindew/featherengine/blob/master/tools/codegen/modifier_api.py): `tools/codegen/modifier_api.py`
- [ECS Modifiers](https://github.com/martindew/featherengine/blob/master/tools/codegen/extensions/ecs.py): `tools/codegen/extensions/ecs.py`
- [Core Modifiers](https://github.com/martindew/featherengine/blob/master/tools/codegen/extensions/core_modifiers.py): `tools/codegen/extensions/core_modifiers.py`

### Other components

- **Engine User**

## Connections

- Engine User → Default Engine: starts
- Default Engine → Resource Loader: indexes project (evidence: `main/default_engine.cpp`)
- Default Engine → World Simulation: initializes and updates (evidence: `main/default_engine.cpp`)
- Default Engine → Display Window: polls updates (evidence: `main/default_engine.cpp`)
- Default Engine → Rendering Server: initializes and updates (evidence: `main/default_engine.cpp`)
- Reflection Generator → Modifier API: uses API (evidence: `tools/codegen/generate_reflection.py`)
- ECS Modifiers → Modifier API: implements (evidence: `tools/codegen/extensions/ecs.py`)
- Core Modifiers → Modifier API: implements (evidence: `tools/codegen/extensions/core_modifiers.py`)
