Skip to content

Feature pointcloud editing#28

Merged
rxdu merged 88 commits into
mainfrom
feature-pointcloud_editing
Apr 26, 2026
Merged

Feature pointcloud editing#28
rxdu merged 88 commits into
mainfrom
feature-pointcloud_editing

Conversation

@rxdu
Copy link
Copy Markdown
Owner

@rxdu rxdu commented Apr 26, 2026

No description provided.

rxdu and others added 28 commits August 29, 2025 19:56
The scenegraph module (state mgmt + command pattern + SceneManagerBridge) and
its object_management demo drifted the library away from its visualization-first
intent into editor-framework territory. The bridge in particular was unsound:
it dynamic_cast'd renderables and fabricated random fallback data via
std::random_device when it could not clone arbitrary OpenGlObjects, so the
"integration" demo was not actually mirroring state to the renderer.

Editing/undo/history will be rebuilt on top of the library inside
sample/editor/ so that the library proper stays a pure visualization toolkit.
The sample will serve as a dogfood check: if it cannot be implemented without
modifying src/, the library is missing a hook.

Build configures and links cleanly. Pre-existing PCLLoaderTest.InvalidFileError
failure is unrelated (PCL no longer throws on corrupt PCDs).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
QuickViz is a visualization library; editor/app-level concerns belong in
sample/, not src/. Codify the rule and enforce it:

- CLAUDE.md: document the boundary explicitly under "Library Boundary",
  refresh the module list (add pcl_bridge, note sample/), and frame samples
  as a dogfood check on library completeness.
- CI: add a boundary-check job that fails if any src/ source includes from
  sample/, or if any src/ CMakeLists pulls in a sample subdirectory. Runs
  fast on Ubuntu and gates the rest of the pipeline naturally.

CMake target hygiene was already correct (modules expose include/ via
BUILD_INTERFACE only), so no Makefile changes needed.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
CLAUDE.md:
- "Build-Upon Components" no longer lists in-library command/undo or scene
  graph frameworks. Editor frameworks are explicitly app-side concerns.
- "Interaction & Editing Patterns" → "Interaction & Tool Patterns".
  Removed the Command/CommandStack code example (editor-side guidance,
  not library guidance) and noted that library tools emit
  selection/hover/measurement events, not history records.

docs/architecture.md: deleted. The "visualization" module section described
an alternative architecture that conflicts with the now-confirmed mission
(library is gldraw + helpers; high-level data mapping happens in apps).

docs/notes/scenegraph_design_proposal.md: deleted. Documented the modal
SceneState design that has been removed; useful only as a "what we tried"
note, and we have it in git history.

TODO.md: rewritten. Removed self-grading and the deleted scenegraph
roadmap. New tracker leads with the reshape state and the actual
visualization gaps (selection coverage, LOD, PCL test fix, large-file
splits, log cleanup).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
A minimal point-cloud editor that exists primarily as the dogfood check
on the library API: it must be implementable without modifying anything
under src/. Built cleanly against the current library, no src/ changes.

MVP scope:
- Load a .pcd / .ply via pcl_bridge
- Render in a viewport with the library's SelectionManager and
  PointSelectionTool
- Delete the selected points (one undoable command)
- Sample-private CommandStack with Undo/Redo, bound to Ctrl+Z /
  Ctrl+Shift+Z / Ctrl+Y, plus a "Delete Selected" button and a minimal
  history panel
- Esc clears selection, Delete/Backspace fires the delete command

Architecture: the editor holds the loaded data as the source of truth
(an alive-mask over the original point array). The library's PointCloud
renderable is the view; commands mutate the alive mask and rebuild the
visible cloud via PointCloud::SetPoints. Selection events arrive with
visible-cloud indices, which the editor maps back to original-array
indices through a small lookup table.

Library-hook candidates discovered while building the sample have been
logged in TODO.md (Step 4 of the reshape plan):
- Stable ObjectId-based access on SceneManager
- ObjectId field on PointSelection
- PointCloud::SetActiveMask / SetActiveIndices to avoid rebuilding the
  vertex buffer on every edit
- Stable point identity so selections survive cloud mutations

These are additive, not blocking; each will be evaluated against the
"is this a visualization concern?" bar before merging into src/.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@rxdu rxdu merged commit 67a7f92 into main Apr 26, 2026
1 of 5 checks passed
@rxdu rxdu deleted the feature-pointcloud_editing branch April 26, 2026 11:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant