| Left click | Select an object |
| Left click + drag | Move selected object on the XZ plane |
| Shift + click | Multi-select (N objects) — for CSG, alignment |
| Right click + drag | Orbit camera around the scene |
| Middle click + drag | Pan camera |
| Scroll wheel | Zoom in / out |
| Double-click on object | Show XYZ dimensions + height/floor, re-center camera |
| Ctrl + D | Duplicate selection |
| Del / Backspace | Delete selection |
| Arrows ↑↓←→ | Move object 1 mm (XZ plane, camera-relative) |
| Page Up / Down | Move object 1 mm (vertical Y axis) |
| L | Show / hide 3D alignment handles |
| S | Enable / disable magnetic snap (1 mm default) |
| N | Toggle light / dark theme |
| 1 | Perspective view |
| 2 | Top view |
| 3 | Front view |
| 4 | Right view |
| 5 | Reset camera (default perspective) |
| Esc | Deselect all / Close dialogs |
| Cube | Box 20×20×20 mm — 6 flat faces, perfect export |
| Sphere | 64×64 segs display / 128×128 export — 0.49 mm/arc at Ø20 mm |
| Cylinder | 64 segs display / 128 segs export |
| Cone | 64 segs display / 128 segs export |
| 3D Text | Helvetiker font, configurable extrusion, bevels |
| Import STL/OBJ | Binary + ASCII, normals preserved, automatic Y↔Z axis conversion |
| ∪ Union | Merges N objects into one solid. Shift+click to select N objects. |
| − Subtract | Subtracts holes from solids. Automatic hole-mode detection. |
| ∩ Intersect | Keeps only the volume common to all selected objects. |
| Hole Mode | Marks an object as a hole (transparent red). Union with a solid = automatic subtraction (Tinkercad mode). |
| 🔧 Re-smooth | Recomputes BFS island normals (crease 30°) on the selected object. |
| 🎨 Recolor | Opens a color picker to recolor after CSG merge. |
| Gizmo ⟳ | Check Gizmo in the Properties panel — 3 XYZ rings appear. Drag a ring to rotate freely. |
| Center of gravity | After CSG merge, the origin is recentered on the real center of gravity (area-weighted centroid). Correct rotations. |
| X/Y/Z axes | Colored discs X (red) Y (green) Z (blue) permanently displayed on the coordinate axes. |
| Floor label | Orange line Floor: ±N mm shown if the object is above or below the grid (y ≠ 0). |
| Activate | Shift+click on ≥ 2 objects, then 📐 Align button or key L — colored 3D handles (X/Y/Z) appear. Direct click on a handle = immediate alignment. |
| X Axis | Left · Center · Right |
| Y Axis | Floor · Center · Top |
| Z Axis | Front · Center · Back |
| Save | Exports a .json file — objects, positions, colors, CSG geometries |
| Load | Reloads a NASSCAD .json file — restores the complete scene |
| Export STL | Slicer format (Cura, PrusaSlicer, Bambu) — Z-up. Adjustable quality: 128 / 256 / 512 segments |
| Export OBJ | Wavefront with vn normals — compatible with Blender, FreeCAD |
| Export 3MF | Native format for Bambu Studio, PrusaSlicer, Cura — per-object colors, Z-up, clean ZIP |
| Import STL/OBJ/3MF | Imports external meshes — automatic centering, placed on floor. 3MF: per-object colors and multi-objects supported |
| STL Quality | Buttons 128 / 256 / 512 in the menubar — number of curve segments at export. 128 = sufficient for 0.4mm FDM |
| 📂 IDB Projects | IDB Projects menu in the menubar — list, load, delete. Double-click to restore. |
| 📁 Folder | Button in the menubar — opens the folder containing the NASSCAD_V4.1.html file |
ArrayBuffer allocated at startup — size chosen via 💾 Pool: 512MB / 1GB / 1.5GB / 2GB in the menubar (default 1 GB). Automatic mini mark-and-sweep garbage collector. Changes apply on page reload.
| Geometry zone | 819 MB — positions / normals / binary indices |
| Snapshot zone | 204 MB — scene states JSON UTF-8 |
| MEM gauge | Bar at bottom right — JS Heap + pool. Hover = full detail. |
| ♻ Flush pool | Toolbar button — manually triggers the mark-and-sweep GC on the GeometryPool. Frees orphan geometries and displays stats in the logs. |
| Rendu Three.js (WebGL — GPU) | |||
| ✅ Fluide | < 500 objects | < 3M vertices | No risk |
| ⚠ Slow | 500–1,000 objects | 3–8M vertices | FPS drop |
| 🔴 Risk | > 1,000 objects | > 8M vertices | Likely freeze |
| Manifold WASM — CSG operations | |||
| ✅ Fast | < 10,000 triangles/object (cube, cone, pyramid…) | < 1 seconde | |
| ⚠ Slow | 10,000–50,000 triangles/object (sphere, half-sphere) | 1–10 secondes | |
| 🔴 Freeze | > 50,000 triangles/object — M threads (63,000 tri) in CSG | > 30 secondes | |
| GeometryPool + Undo/Redo (2 Go) | |||
| ✅ Safe | < 150 complex objects, < 8 active undo levels | Pool < 50% | |
| 🔴 Saturation | > 300 objects or massive CSG snapshots | Red MEM gauge | |
| Conseils pratiques | |||
|
· M threads: place without CSG — let the slicer (Cura/PrusaSlicer) handle assembly · Complex CSG: first reduce simple object groups with Union, then subtract · MEM gauge > 70%: save the project and reload the page to free memory · STL export: 128 segs — sufficient quality for FDM printing (printer resolution > 0.2mm) |
|||
| CSG Engine | |
| Manifold.union(N) | Native N-ary C++ WASM merge — 1 call for N objects |
| _threeToManifold() | Vertex merge epsilon 1e-5 + matrixWorld applied before sending to Manifold |
| _manifoldToThree() | getMesh() → BufferGeometry + automatic smoothing pipeline |
| Auto solid/hole detection | If Solid+Hole mix → forced subtract (Tinkercad behavior) |
| file:// patch | manifold.js converted to IIFE — removal of import(), fetch(), export default. Compatible with file:// |
| WASM base64 inline | manifold.wasm base64-encoded in HTML — decoded via atob() at runtime. Zero network. |
| Normal smoothing (Blender algorithm) | |
| mergeVertices() | Epsilon 1e-4 quantization via Map — merges coincident vertices |
| computeFaceNormals() | Face normal by cross product (c−a)×(b−a) normalized |
| BFS continuity islands | Breadth-first traversal by edges — groups faces whose angle < crease angle |
| smoothNormalsWithCrease() | Crease angle 30° — per-island smoothing, sharp edges preserved, vertices duplicated |
| postProcessCSGGeo() | Full pipeline automatically applied to each CSG result |
| Center of gravity | |
| computeCenterOfGravity() | Area-weighted centroid — Σ(centroid × area) / Σ(area) — O(n triangles) |
| Automatic recentering | geo.translate(-CG) + mesh.position=CG — object in place, origin = real CG |
| Memory management | |
| Bump allocator | Zone-growing pointer — O(1) allocation |
| Free-list | FLAG_FREE slots reused first before bump |
| Mark-and-sweep GC | Mark: walks objs[]._poolSlot — Sweep: frees orphans — Compact: recalculates ptrs |
| XOR checksum | XOR of first 256 bytes per slot — corruption detection |
| 3D rendering and interface | |
| Dual resolution | SEG_VIEW 64 segs (display) / SEG_PRINT 128 segs (export) — recomputed on the fly |
| Custom OrbitControls | Spherical camera theta/phi/dist with damping — no external plugin |
| Rotation gizmo | TorusGeometry XYZ rings detected by raycaster, rotation by drag. Radius calibrated to bbox. |
| 2D Canvas labels | 2D canvas overlay — XYZ dimensions + height/floor (±mm) projected in real time |
| X/Y/Z axis labels | 3D→2D projection via cam.project() — colored discs drawn on canvas overlay |
| Magnetic snap | Position quantization to N mm — activated by key S or toolbar button |
| Spinner overlay | Animated CSS ring position:fixed — shown during CSG, import, 3D text |
| IndexedDB persistence | Named projects, quota displayed, restore on reload |
| NASSCAD V4.1 — Marseille, April 2026 | |
| ✍ NASSER Architect & Tester |
CLIT · Electronics technician · 3D Maker · Marseille Vision, direction, critical bug identification (CSG sizes, manifold, worker), quality standards, field testing, technology pivots. Rare profile: < 0.1% of AI users. |
| 🤖 Claude Sonnet 4.6 Developer |
Artificial Intelligence · Anthropic Web Worker Manifold WASM · Watertight primitives · Manifold geometries verified edge by edge · Surgical patches · Systematic node --check. |
| Architecture V4.2.6: Three.js r128 · Manifold WASM (Web Worker) · Render gate _camDirty (GPU au repos si scène statique) · Snapshots undo base64 Float32 (4× compact, normales préservées) · Caches O(1) raycaster (_meshList / _meshMap / _idMap) · selOnly DOM diff · GeometryPool 512MB–2GB · IndexedDB · 10 primitives watertight · Export STL/OBJ/3MF · Import STL/OBJ/3MF · Qualité export 128/256/512 segs · Undo/Redo 10 niveaux · Snap 0.1mm · Filetages M2–M20 | |
| "La patience est la rançon du succès." — NASSER, 2026 | |
Technologies used:
· Manifold (Emmett Lalish et al.) — Apache 2.0 — open-source C++ CSG engine
· Three.js (Mr.doob and community) — MIT — 3D WebGL engine
· Helvetiker font — MIT — 3D font
All licenses are permissive — distribution and commercial use allowed.
⚖ NASSCAD V4.2 License
© 2026 NassLab — Nasser, Marseille, France
INPI e-Soleau deposit: DSO2026010838
This software is distributed under the Creative Commons BY-NC 4.0 license:
· Personal and non-commercial use — free, redistribution allowed with attribution
· Commercial use — written agreement required from NassLab
No implied warranty. The author cannot be held liable for any damage resulting from the use of this software.