Implement Mesh partitioning

This commit is contained in:
2026-09-27 17:48:22 +02:00
parent 11426fe8fb
commit 850a6f601b
21 changed files with 1146638 additions and 181 deletions

119
README.md
View File

@@ -28,75 +28,72 @@ This is the current state of the engine architecture:
```mermaid
flowchart TB
subgraph Infrastructure["Infrastructure"]
direction LR
subgraph Platform
direction TB
Window --> GLFW
Window --> glad
Window --> ImGui["Dear ImGui"]
end
subgraph Loading
direction TB
Loader --> tinyobjloader
Loader --> stb_image
end
end
subgraph Application
Renderer
Scene
Camera
direction LR
Framebuffer
Renderer --> Camera
Renderer --> Scene
Renderer -->|Updates| UniformBuffer
end
subgraph World
Entity
Transform
Mesh
Material
LightEnvironment
direction LR
subgraph SceneGraph["Scene Graph"]
direction TB
Scene --> Entity
Entity --> Transform
Entity --> Mesh
Entity -.->|Optional override| Material
Mesh -->|Partitions| SubMesh
SubMesh -->|Owns| Material
end
subgraph Lighting
direction TB
Scene --> LightEnvironment
LightEnvironment --> DirectionalLight
LightEnvironment --> PointLight
LightEnvironment --> SpotLight
end
end
subgraph SceneData["Scene Data"]
Vertices
Indices
Shader
Texture
UniformBuffer
DirectionalLight
PointLight
SpotLight
direction LR
subgraph Geometry
direction TB
Mesh --> Vertices
Mesh --> Indices
end
subgraph Resources
direction TB
Material --> Shader
Material --> Texture
UniformBuffer -->|Global data| Shader
end
end
subgraph Loading
Loader
tinyobjloader
stb_image
end
subgraph Platform
Window
GLFW
glad
ImGui["Dear ImGui"]
end
Renderer --> Scene
Renderer --> Camera
Renderer --> UniformBuffer
Scene --> Entity
Scene --> LightEnvironment
Entity --> Transform
Entity --> Mesh
Entity --> Material
Mesh --> Vertices
Mesh --> Indices
Material --> Shader
Material --> Texture
Shader --> UniformBuffer
LightEnvironment --> DirectionalLight
LightEnvironment --> PointLight
LightEnvironment --> SpotLight
Loader --> tinyobjloader
tinyobjloader --> Entity
Texture --> stb_image
Window --> GLFW
Window --> glad
Window --> ImGui
tinyobjloader -->|Generates| Entity
Texture -.->|Decodes via| stb_image
classDef application fill:#7c3aed,stroke:#4c1d95,color:#fff
classDef world fill:#2563eb,stroke:#1e3a8a,color:#fff
@@ -105,8 +102,8 @@ flowchart TB
classDef platform fill:#64748b,stroke:#334155,color:#fff
class Renderer,Scene,Camera,Framebuffer application
class Entity,Transform,Mesh,Material,LightEnvironment world
class Vertices,Indices,Shader,Texture,UniformBuffer,DirectionalLight,PointLight,SpotLight data
class Entity,Transform,Mesh,SubMesh,Material,LightEnvironment world
class UniformBuffer,Shader,Texture,Vertices,Indices,DirectionalLight,PointLight,SpotLight data
class Loader,tinyobjloader,stb_image loading
class Window,GLFW,glad,ImGui platform
```