How delarge95/webgl-thesis-proposal works
1. Repository shape
- This repo is a mixed academic + product workspace.
- The runtime product lives in desarrollo/unity_project, while docs/ contains a separate Vite/React site and published WebGL build artifacts.
- Propuesta/ and Informe_final/ are thesis/report deliverables, not part of the app runtime.
2. Primary runtime boundary: Unity WebGL app
- The core application is a Unity 6 LTS project configured for URP and WebGL 2.0.
- The deployable output is a browser-executed WebAssembly/WebGL build, with a custom WebGL template under Assets/WebGLTemplates/Custom.
- The project is split with assembly definitions for at least two code domains: Core and UI.
3. Scene and bootstrap flow
- The main scene is Assets/Scenes/MainScene_Final.unity, with a lighter MainScene.unity variant also present.
- Initialization is handled through bootstrap-style utilities such as SceneBootstrapper, ProjectSetupWizard, and editor-side scene/config fixers.
- The scene is assembled around managers rather than heavyweight scene logic, which is important for diagramming the system as a service-oriented Unity app.
4. Domain model and content data
- Drone component metadata is data-driven through DronePartData and AssemblyGuideData.
- Part definitions are stored in Assets/Data/Parts/ as serialized asset files, representing the authoritative source for labels, states, and part-specific metadata.
- 3D source assets come from Blender files in blender_files/, plus supporting research/inventory material under desarrollo/docs/investigacion/.
5. Interaction and application state
- The runtime is organized around AppStateMachine and a centralized EventBus, with CoreEvents / StateChangedEvent used for loose coupling.
- InputManager, SelectionManager, OrbitCameraController, and CursorManager form the front door for user interaction.
- Selected objects and UI modes are not tightly bound to the scene; they propagate through events and manager state, which is the key architectural boundary to show.
6. Visualization subsystem
- The visual layer is driven by custom URP shaders in Assets/Shaders/ and shader-driven materials.
- Visualization modes include realistic, x-ray, blueprint, solid color, wireframe, ghosted, and thermal, handled by ViewModeManager.
- Cross-section, edge detection, and clipping are separate rendering concerns, with their own managers and shaders (CrossSectionManager, EdgeDetectionFeature, ClippableLit, XRay, Thermal, WireframeWebGL, etc.).
7. Drone assembly and exploded-view mechanics
- Physical structure and part separation are managed by ExplodablePart, ExplodedViewManager, DroneAssembler, DronePartSetup, and ModularPartsSystem.
- The exploded view is not just an animation; it is a system that coordinates part transforms, selection states, and view updates.
- DroneStateController adds simulation-oriented behavior such as on/off state and propeller/status effects.
8. Engineer-oriented tools
- The app includes several specialist tools that should be shown as sibling subsystems in the diagram:
- MeasurementTool for geometric measurement
- AnnotationSystem for 3D notes
- AssemblyGuideManager and AssemblyChecklist for guided procedures
- BillOfMaterialsManager for parts inventory/export
- ConnectionPointsViewer for assembly interfaces
- These tools depend on shared selection/data/state but are logically separate from the rendering pipeline.
9. UI architecture
- The UI layer is built with UI Toolkit and structured through layouts, styles, panels, and controller classes under Assets/Scripts/UI/.
- UIManager, UIModeController, mode handlers, loading/hero/overlay panels, and hotspot/detail components mediate between the user and the core managers.
- Procedural icon generators under UI/ProceduralIcons are part of the UI asset pipeline, not just decorative assets.
10. Editor automation and build support
- The project includes a substantial editor-only subsystem under Assets/Editor/Antigravity/ and related setup tools.
- These scripts handle project setup, WebGL fixes, URP assignment, shader inclusion, quality settings, and build remediation.
- This boundary matters because a significant amount of repository logic exists to make the Unity/WebGL build reliable and reproducible.
11. Performance and runtime utilities
- Shared infrastructure lives in Core/Utils: Singleton, ServiceLocator, TweenEngine, FPSCounter, and WebGLProfiler.
- Runtime quality control is managed by QualityManager, AssetLoader, SaveSystem, ErrorHandler, and AnalyticsManager.
- The architectural style is deliberately manager-heavy, but the actual decoupling mechanism is the event bus plus singleton/service-locator support.
12. Testing, audits, and documentation layer
- There are editor tests under Assets/Scripts/Tests/Editor/, mainly around data integrity and the event bus.
- The repository also contains extensive audits, UX reports, deployment guides, and technical manuals in both desarrollo/docs/ and Informe_final/.
- These documents are part of the project’s delivery architecture: they describe and validate the runtime system but are not runtime dependencies.
13. Secondary web/documentation app
- docs/ is a separate front-end project using Vite + React with its own components, hooks, and build output.
- It serves as the public-facing documentation/portfolio site and also contains a committed WebGL build under docs/Build/.
- A GitHub Pages workflow (.github/workflows/pages.yml) indicates that this site is deployed independently from the Unity source project.
14. How to draw the architecture diagram
- Center the diagram on the Unity runtime with three layers: scene/bootstrap, core managers/data, and UI/rendering.
- Show external inputs from Blender/source assets and generated ScriptableObject-style part data flowing into the runtime.
- Show the editor/build toolchain and the docs/React site as adjacent but separate delivery surfaces.
- Emphasize event-driven communication between managers instead of direct point-to-point coupling.
Main entry points: EventBus.cs Event bus · SceneBootstrapper.cs Scene bootstrap · UIManager.cs UI layer · 01_pipeline_modelado_hard_surface.md Research docs
Components 22
Unity runtime
Browser-delivered Unity WebGL application and its internal app layers.
- Scene bootstrap · Bootstraps the main scene and initializes shared runtime services.
desarrollo/unity_project/Assets/Scripts/Core/Utils/SceneBootstrapper.cs - App state · Central application state and lifecycle coordination.
desarrollo/unity_project/Assets/Scripts/Core/Managers/AppStateMachine.cs - Event bus · Loose-coupling mechanism for runtime events and state changes.
desarrollo/unity_project/Assets/Scripts/Core/Events/EventBus.cs - Part data · Authoritative drone part and assembly guide metadata.
desarrollo/unity_project/Assets/Scripts/Core/Data/DronePartData.cs - Part catalog · Loads and exposes part inventory and lookup behavior.
desarrollo/unity_project/Assets/Scripts/Core/Managers/PartCatalogManager.cs - Assembly system · Coordinates exploded view, part setup, assembly flow, and stateful drone behavior.
desarrollo/unity_project/Assets/Scripts/Core/Utils/DroneAssembler.cs - Interaction front · User input, object selection, camera orbit, and cursor state.
desarrollo/unity_project/Assets/Scripts/Core/Managers/InputManager.cs - View modes · Switches between realism, x-ray, blueprint, thermal, wireframe, and related display modes.
desarrollo/unity_project/Assets/Scripts/Core/Managers/ViewModeManager.cs - Render effects · Cross-section, edge detection, clipping, and material-driven rendering behavior.
desarrollo/unity_project/Assets/Scripts/Core/Managers/CrossSectionManager.cs - UI layer · Runtime UI controllers, layouts, mode handlers, hotspots, and procedural icons.
desarrollo/unity_project/Assets/Scripts/UI/UIManager.cs - Specialist tools · Measurement, annotations, checklist guidance, BOM, and connection-point viewing.
desarrollo/unity_project/Assets/Scripts/Core/Managers/MeasurementTool.cs - Runtime utils · Singletons, service location, tweening, profiling, saving, analytics, and error handling.
desarrollo/unity_project/Assets/Scripts/Core/Utils/Singleton.cs - Main scene · Primary runtime scene assembled around managers and bootstrap components.
desarrollo/unity_project/Assets/Scenes/MainScene_Final.unity
Build tooling
Editor automation, WebGL remediation, and project setup support.
- Project setup · Editor-side setup, scene fixes, URP assignment, and WebGL remediation.
desarrollo/unity_project/Assets/Scripts/Editor/ProjectSetupWizard.cs - Build fixers · Graphics, shader inclusion, quality, and WebGL-specific repair scripts.
desarrollo/unity_project/Assets/Editor/Antigravity/WebGLBuildFixer.cs - WebGL template · Custom WebGL host template and styling used by the Unity build.
desarrollo/unity_project/Assets/WebGLTemplates/Custom/index.html
Docs site
Separate Vite/React delivery surface and published build artifacts.
- Docs app · Separate public-facing documentation and portfolio site.
docs/src/App.jsx - Docs build · Committed WebGL output served alongside the docs site.
docs/Build/index.html
Deliverables
Thesis, proposal, and report outputs that document the project.
- Proposal · Project proposal and supporting academic materials.
Propuesta/final_proposal.tex - Final report · Final thesis and technical documentation for the project.
Informe_final/informe_final.tex
Source assets
External 3D/model inputs and authored data feeding the Unity project.
- Blender source · Authoring files for the drone model and related 3D content.
blender_files/drone_00.blend - Research docs · Modeling, shader, WebGL, UX, and inventory research feeding the runtime.
desarrollo/docs/investigacion/01_pipeline_modelado_hard_surface.md
Connections 25
- Blender source → Part data: model metadata · 3D source assets inform the authored part and assembly data.
- Research docs → Part data: specifies · Research and inventory work shape the authoritative part definitions.
- Research docs → Render effects: informs · Shader and visualization research guides the rendering subsystem.
- Scene bootstrap → Main scene: initializes · Bootstraps the main runtime scene.
- Scene bootstrap → App state: starts · Creates the application state machine during scene startup.
- Scene bootstrap → Runtime utils: wires services · Registers shared services and singleton infrastructure.
- App state → Event bus: publishes · State transitions are broadcast through the event bus.
- Interaction front → Event bus: sends events · Input and selection changes propagate through shared events.
- Event bus → UI layer: updates · UI reacts to broadcast state and selection changes.
- Event bus → Assembly system: coordinates · Assembly and exploded-view behavior is driven by shared events.
- Event bus → Specialist tools: feeds · Measurement, annotation, and guidance tools consume shared state.
- Part data → Part catalog: loads into · Serialized part data is loaded by the catalog manager.
- Part catalog → Assembly system: drives · Catalog data informs assembly and part setup.
- Assembly system → View modes: syncs · Exploded-view state and display mode changes stay aligned.
- View modes → Render effects: selects · Visualization modes activate shader and render-effect paths.
- UI layer → Interaction front: controls · UI panels and modes mediate user interaction.
- UI layer → Specialist tools: launches · UI exposes the specialist engineering tools.
- Runtime utils → Build fixers: supports · Shared infrastructure underpins runtime diagnostics and build reliability.
- Project setup → Main scene: repairs · Editor automation keeps scenes and configuration consistent.
- Project setup → Build fixers: invokes · Project setup coordinates WebGL and URP fixers.
- Build fixers → WebGL template: configures · Editor tooling aligns the custom WebGL host template and assets.
- WebGL template → Main scene: hosts · The Unity build renders through the custom WebGL template.
- Docs app → Docs build: produces · The Vite/React site publishes the committed WebGL build surface.
- Proposal → Final report: evolves into · Proposal materials feed the final thesis deliverable.
- Final report → Research docs: documents · Final academic documentation captures the research and implementation work.