Digital Arts
My sixth form Computer Science NEA, a Blender-style 3D training suite that runs in the browser with JavaScript and WebGL2.
- 37k
- Lines of code
- 1,532
- Automated checks
Digital Arts is a training suite for 3D artists. It has a mesh editor, training units, a content browser and an admin area, written in plain ES modules with no framework.
The viewport runs on WebGL2 with GPU depth testing, a quad wireframe, a ground grid and colour-ID picking. Data is stored in SQLite compiled to WebAssembly and persisted to IndexedDB, so the app runs without a server. The test suite has 1,532 checks across 8 suites.
This is my NEA, and I can't share the source until it ends at the end of the school year. The next work is the dirty-flagged geometry upload, a selection highlight pass and the 60 FPS validation.
Breakdown
Three layers
How the core, the WebGL2 renderer and the UI are separated.
Half-edge mesh
Replacing position matching with exact adjacency data.
Tools and modifiers
24 mesh tools and a non-destructive modifier stack.
Undo and snapping
A command stack for undo, and a snapping system modelled on Blender's.
WebGL2 viewport
GPU depth testing, a quad wireframe, a ground grid and colour-ID picking.
Mesh decimation
Reducing triangle counts with quadric error edge collapse.
Picking
Selecting objects and faces with a colour-ID render pass.
Materials
PBR materials with texture maps, a material library and .mtl import and export.
Accounts and data
A SQLite database in the browser, with eight tables queried in plain SQL and persisted to IndexedDB.
Testing
1,532 checks across 8 suites, run without a browser window.