k3d

SPEC.md — libGDX Mesh Editor (SketchUp-like) — Kotlin Desktop

1. Product goal

A desktop 3D modeling application focused on SketchUp-style direct modeling:

Primary target: desktop (LWJGL3) first.


2. Core concepts and terminology

Entities

Editing contexts


3. MVP feature set (baseline from your requirements)

3.1 Viewport interaction

3.2 Grid System (Implemented)

3.3 Drawing and creation

3.4 Cutting / splitting

3.4 Selection

3.5 Snapping (inference)

3.6 Rendering


4.1 Inference engine (high impact)

Add SketchUp-like inference behaviors beyond simple snapping:

Acceptance criteria:

4.2 Measurement input (high impact)

Units:

4.3 Groups and Components (essential for SketchUp-like workflow)

4.4 Visibility / organization

4.5 Materials and UV basics (important for modeling apps)

4.6 Smoothing / soft edges (important for “nice” models)

4.7 Section plane (useful for inspection; optional v1.1)

4.8 Scenes (optional)


5. UX and interaction design

5.1 Tool system

Tools similar to SketchUp:

Each tool has:

5.2 Modifiers (suggested defaults; configurable)

5.3 Visual feedback


6. Geometry and modeling rules

6.1 Planarity and face creation

6.2 “Sticky” geometry

SketchUp-like behavior:

6.3 Precision and tolerances

6.4 Robust cutting


7. Rendering requirements

7.1 Viewport

7.2 Shadows

7.3 Picking


8. Data model and file IO

8.1 In-memory model

Recommended structure:

8.2 Persistence

8.3 Import/Export (later)


9. UI requirements (2D)

9.1 Layout

9.2 Implemented UI Features

9.2 Command system


10. Undo/Redo (must-have)


11. Performance requirements

11.1 Implemented Persistence Features

11.2 Implemented Plugin System


12. Non-goals (for now)


13. Acceptance tests (high-level)

  1. Draw rectangle on ground plane by inference and typed dimensions → creates a face.
  2. Push/Pull face by typed distance → creates a watertight prism.
  3. Draw a diagonal line across top face → face splits into two faces.
  4. Window-select right-to-left selects intersected edges; left-to-right selects only inside.
  5. Double-click selects connected geometry of a face and its boundary edges.
  6. Group geometry; draw a line through it outside group context → group geometry is not cut.
  7. Snap to midpoint and endpoint is stable while orbiting.
  8. Shadows render without severe acne or peter-panning at default settings.