|
MorphologicalAttributeFilters
Public API documentation
|
Edit-session facade for ValuedMorphologicalTree.
More...
#include <ValuedMorphologicalTree.hpp>
Public Member Functions | |
| ValuedMorphologicalTreeEditor (const ValuedMorphologicalTreeEditor &)=delete | |
| Disables copy construction. | |
| ValuedMorphologicalTreeEditor & | operator= (const ValuedMorphologicalTreeEditor &)=delete |
| Disables copy assignment. | |
| ValuedMorphologicalTreeEditor (ValuedMorphologicalTreeEditor &&other) noexcept | |
| Transfers the active valued-tree edit session and rollback journal. | |
| ValuedMorphologicalTreeEditor & | operator= (ValuedMorphologicalTreeEditor &&)=delete |
| Disables move assignment. | |
| ~ValuedMorphologicalTreeEditor () | |
| Restores the altitude journal and closes the valued-tree edit session. | |
| bool | canRollback () const noexcept |
| Tests whether topology and altitude can be rolled back. | |
| void | rollback () |
| Restores topology and altitude captured by the delta journals. | |
| NodeId | createDetachedNode (T altitude=T{}) |
| Creates a detached topology node and initializes its altitude. | |
| void | setNodeAltitude (NodeId nodeId, T altitude) |
| Sets a live node altitude during a staged topology edit. | |
| void | detach (NodeId nodeId) |
| Detaches one non-root node through the structural editor. | |
| void | reparent (NodeId nodeId, NodeId newParentId) |
| Reparents one node through the structural editor. | |
| void | attach (NodeId parentId, NodeId detachedNodeId) |
| Attaches one detached node through the structural editor. | |
| void | moveChildren (NodeId parentId, NodeId sourceId) |
Moves all direct children from sourceId under parentId. | |
| void | movePixelToProperPart (NodeId targetNodeId, NodeId sourceNodeId, PixelId pixel) |
| Moves one direct proper part between nodes. | |
| void | mergeProperParts (NodeId targetNodeId, NodeId sourceNodeId) |
| Moves all direct proper parts between nodes. | |
| void | removeChild (NodeId parentNodeId, NodeId childId, bool releaseNodeFlag) |
| Detaches a direct child and optionally releases an empty node slot. | |
| void | releaseNode (NodeId nodeId) |
| Releases an empty detached node slot. | |
| void | setRoot (NodeId nodeId) |
| Promotes one node to the topology root. | |
| void | pruneNode (NodeId nodeId) |
| Applies the topology prune helper inside the valued-tree edit session. | |
| void | mergeNodeIntoParent (NodeId nodeId) |
| Applies the topology merge helper inside the valued-tree edit session. | |
| bool | hasDetachedAliveNodes () const noexcept |
| Returns whether the structural edit still has detached live nodes. | |
| TreeEditor::IncrementalProof | proveIncremental () |
| Produces a generic move-only proof for the current valued-tree edit revision. | |
| void | commit (TreeEditor::IncrementalProof &&proof) |
Commits the exact valued-tree edit revision represented by proof. | |
| TreeValidationResult | validate () const noexcept |
| Validates only the staged topology. | |
| TreeValidationResult | validateAndCommit () noexcept |
| Validates topology, validates altitude order, then closes the edit. | |
| void | commit () |
Exception-based wrapper around validateAndCommit(). | |
Friends | |
| class | ValuedMorphologicalTree< T > |
| ValuedMorphologicalTreeEditor< T > | detail::beginEstablishedValuedEdit (ValuedMorphologicalTree< T > &tree) |
Grants detail::beginEstablishedValuedEdit access to the enclosing type. | |
Edit-session facade for ValuedMorphologicalTree.
The valued-tree editor reuses the structural TreeEditor for topology while keeping the external altitude buffer as the canonical valued-tree state. commit() first validates the topology and then validates monotone altitude.
Definition at line 370 of file ValuedMorphologicalTree.hpp.
|
inlinenoexcept |
Transfers the active valued-tree edit session and rollback journal.
| other | Object to compare with or transfer from. |
Definition at line 486 of file ValuedMorphologicalTree.hpp.
|
inline |
Restores the altitude journal and closes the valued-tree edit session.
Definition at line 501 of file ValuedMorphologicalTree.hpp.
|
inline |
Attaches one detached node through the structural editor.
| parentId | Identifier of the parent node. |
| detachedNodeId | Node identifier. |
Definition at line 592 of file ValuedMorphologicalTree.hpp.
|
inlinenoexcept |
Tests whether topology and altitude can be rolled back.
Definition at line 508 of file ValuedMorphologicalTree.hpp.
|
inline |
Exception-based wrapper around validateAndCommit().
Definition at line 775 of file ValuedMorphologicalTree.hpp.
|
inline |
Commits the exact valued-tree edit revision represented by proof.
| proof | Validation proof consumed by the operation. |
Definition at line 731 of file ValuedMorphologicalTree.hpp.
|
inline |
Creates a detached topology node and initializes its altitude.
The altitude buffer is reserved before mutating the topology so allocation failure cannot leave a new node without a matching altitude slot.
| altitude | Altitude data indexed by node identifier. |
Definition at line 530 of file ValuedMorphologicalTree.hpp.
|
inline |
Detaches one non-root node through the structural editor.
| nodeId | Dense internal node identifier. |
Definition at line 570 of file ValuedMorphologicalTree.hpp.
|
inlinenoexcept |
Returns whether the structural edit still has detached live nodes.
Definition at line 688 of file ValuedMorphologicalTree.hpp.
|
inline |
Applies the topology merge helper inside the valued-tree edit session.
| nodeId | Dense internal node identifier. |
Definition at line 678 of file ValuedMorphologicalTree.hpp.
|
inline |
Moves all direct proper parts between nodes.
| targetNodeId | Node identifier. |
| sourceNodeId | Node identifier. |
Definition at line 626 of file ValuedMorphologicalTree.hpp.
|
inline |
Moves all direct children from sourceId under parentId.
| parentId | Identifier of the parent node. |
| sourceId | Input. |
Definition at line 603 of file ValuedMorphologicalTree.hpp.
|
inline |
Moves one direct proper part between nodes.
| targetNodeId | Node identifier. |
| sourceNodeId | Node identifier. |
| pixel | Proper-part identifier. |
Definition at line 615 of file ValuedMorphologicalTree.hpp.
|
inline |
Produces a generic move-only proof for the current valued-tree edit revision.
Topology is checked on the mutation delta whenever every primitive is supported. Altitude order is then checked only around touched nodes. A topology fallback also selects complete altitude validation.
Definition at line 700 of file ValuedMorphologicalTree.hpp.
|
inline |
Applies the topology prune helper inside the valued-tree edit session.
| nodeId | Dense internal node identifier. |
Definition at line 668 of file ValuedMorphologicalTree.hpp.
|
inline |
Releases an empty detached node slot.
| nodeId | Dense internal node identifier. |
Definition at line 648 of file ValuedMorphologicalTree.hpp.
|
inline |
Detaches a direct child and optionally releases an empty node slot.
| parentNodeId | Identifier of the parent node. |
| childId | Identifier of the child node. |
| releaseNodeFlag | Flag controlling release node flag. |
Definition at line 638 of file ValuedMorphologicalTree.hpp.
|
inline |
Reparents one node through the structural editor.
| nodeId | Dense internal node identifier. |
| newParentId | Parent-node value. |
Definition at line 581 of file ValuedMorphologicalTree.hpp.
|
inline |
Restores topology and altitude captured by the delta journals.
Definition at line 513 of file ValuedMorphologicalTree.hpp.
|
inline |
Sets a live node altitude during a staged topology edit.
Monotone order is intentionally checked at valued-tree commit time because intermediate staged topologies may not yet have final parent/child relations.
| nodeId | Dense internal node identifier. |
| altitude | Altitude data indexed by node identifier. |
Definition at line 554 of file ValuedMorphologicalTree.hpp.
|
inline |
Promotes one node to the topology root.
| nodeId | Dense internal node identifier. |
Definition at line 658 of file ValuedMorphologicalTree.hpp.
|
inlinenoexcept |
Validates only the staged topology.
Altitude monotonicity is checked by validateAndCommit() / commit().
Definition at line 747 of file ValuedMorphologicalTree.hpp.
|
inlinenoexcept |
Validates topology, validates altitude order, then closes the edit.
Definition at line 754 of file ValuedMorphologicalTree.hpp.
|
friend |
Definition at line 360 of file ValuedMorphologicalTree.hpp.