Skip to content

Paint v2: Slice J — CLI/MCP parity, docs, tests #553

@fernandotonon

Description

@fernandotonon

Parent epic: #543
Depends on: Slices A–I (functionally needs A, B, C, D, I minimum)

Goal

Bring Paint v2 to project conventions: CLI, MCP, breadcrumbs, tests, docs.

Scope

  • CLI — new qtmesh paint subcommand:
    • qtmesh paint model.fbx --layer add --name <n> --channel BaseColor -o out.fbx
    • qtmesh paint model.fbx --layer list [--json]
    • qtmesh paint model.fbx --layer merge-down --layer <n> -o out.fbx
    • qtmesh paint model.fbx --layer flatten -o out.fbx
    • qtmesh paint model.fbx --bake --engine unity --resolution 2048 -o out/
    • qtmesh paint model.fbx --apply-stencil <image.png> --camera "x,y,z,target" --channel BaseColor -o out.fbx
    • qtmesh paint --list-stamps, --list-presets, --list-palettes
    • Live stroke authoring is not in CLI scope.
  • MCP tools:
    • paint_add_layer, paint_delete_layer, paint_reorder_layer, paint_merge_down, paint_flatten
    • paint_set_active_layer, paint_set_active_channel, paint_set_brush_preset, paint_set_color, paint_set_gradient
    • paint_apply_decal, paint_apply_stencil
    • paint_bake_pbr with engine target
    • JSON-RPC, main thread, no BlockingQueuedConnection.
  • Sentry breadcrumbs (consolidated): paint.brush.*, paint.layer.*, paint.channel.*, paint.symmetry, paint.stabilizer, paint.projection.*, paint.decal.*, paint.derived_map.*, paint.tablet, paint.preset.apply, paint.palette.apply, paint.bake.*. ui.action for menu/toolbar clicks.
  • Tests:
    • BrushEngine_test.cpp — gradients (Slice A), stamps (B), pressure (H).
    • PaintLayerStack_test.cpp — blend modes + composite (C).
    • PaintChannelRouter_test.cpp — channel dispatch + normal-from-height (D).
    • SymmetryEngine_test.cpp — axis-mirror correctness (E).
    • ProjectionPainter_test.cpp — projection / decal commit (F).
    • DerivedMaps_test.cpp — cavity / curvature / AO bake (G).
    • All headless-CI safe.
  • Docs:
    • Replace MVP "Paint" section in CLAUDE.md with v2 architecture: layer stack, brush engine, channel router, symmetry, projection, derived maps, bake-up.
    • Add qtmesh paint examples to the CLI block.
    • Document on-disk layout (<AppData>/paint/...).
    • User-facing changelog summarising v2 features.

Acceptance Criteria

  • Every CLI subcommand listed works with --json where applicable.
  • Every MCP tool works via stdio + HTTP.
  • CLI ↔ GUI ↔ MCP parity for every scriptable paint op.
  • Breadcrumbs emitted for every user-visible paint action.
  • All listed test files exist and pass on Linux / macOS / Windows CI.
  • CLAUDE.md Paint section rewritten and accurate.

Effort

~6 days.

Metadata

Metadata

Assignees

No one assigned

    Labels

    cliCommand-line / qtmeshdocumentationImprovements or additions to documentationenhancementNew feature or requestpaintPaint tools (vertex, texture, projection, layers, brushes)

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions