|
mmcfilters
Public API documentation
|
Incremental bounding-box scalar attribute. More...
#include <DynamicTreeAttributeComputer.hpp>


Public Types | |
| using | buffer_type = typename base_t::buffer_type |
| Dense per-node bounding-box attribute buffer inherited from the dynamic protocol. | |
Public Types inherited from mmcfilters::adjust::DynamicTreeAttributeComputer< T > | |
| using | buffer_type = std::vector< double > |
| Dense per-node attribute buffer used by dynamic adjustment computers. | |
Public Member Functions | |
| DynamicBoundingBoxAttributeComputer (BoundingBoxMeasure measure=BoundingBoxMeasure::DiagonalLength) | |
| Creates a bounding-box computer returning the requested scalar measure. | |
| void | resize (const ValuedMorphologicalTree< T > &tree, buffer_type &buffer) const override |
| Resizes public and auxiliary buffers to the current tree slot space. | |
| void | preProcessing (NodeId nodeId, const ValuedMorphologicalTree< T > &tree, buffer_type &) const override |
| Initializes one node's subtree bounding box from its proper part. | |
| void | mergeProcessing (NodeId parentId, NodeId childId, const ValuedMorphologicalTree< T > &, buffer_type &) const override |
| Accumulates a child subtree box into its parent subtree box. | |
| void | postProcessing (NodeId nodeId, const ValuedMorphologicalTree< T > &, buffer_type &buffer) const override |
| Converts the accumulated subtree box into the configured scalar measure. | |
| void | onMoveProperParts (NodeId targetId, NodeId sourceId, const ValuedMorphologicalTree< T > &tree) const override |
Updates local boxes after all proper parts move from sourceId to targetId. | |
| void | onMoveProperPart (NodeId targetId, NodeId sourceId, PixelId pixelId, const ValuedMorphologicalTree< T > &tree) const override |
| Updates local boxes after one proper part moves between nodes. | |
| void | onNodeRemoved (NodeId nodeId, const ValuedMorphologicalTree< T > &) const override |
| Clears auxiliary summaries associated with a released node slot. | |
Public Member Functions inherited from mmcfilters::adjust::DynamicTreeAttributeComputer< T > | |
| virtual | ~DynamicTreeAttributeComputer ()=default |
| Destroys a dynamic attribute computer through the protocol base. | |
| void | computeAttribute (const ValuedMorphologicalTree< T > &tree, buffer_type &buffer) const |
| Computes the attribute for the full current tree in post-order. | |
| void | computeAttributeOnNode (const ValuedMorphologicalTree< T > &tree, NodeId nodeId, buffer_type &buffer) const |
| Recomputes one node assuming all direct children are already up to date. | |
Incremental bounding-box scalar attribute.
The computer keeps two levels of cached state:
local_: bounding box of the node's proper part, including enough extremum multiplicities to update most single-pixel removals without a scan;subtree_: bounding box after child aggregation for the current pre/merge/post pass.Single proper-part moves update the receiver eagerly. The donor is kept exact unless the moved pixel exhausts one extremum, in which case its local summary is marked dirty and rebuilt lazily on the next access. This preserves the local-update structure of the Higra version while adapting coordinates to this project's row-major image domain.
Definition at line 238 of file DynamicTreeAttributeComputer.hpp.
| using mmcfilters::adjust::DynamicBoundingBoxAttributeComputer< T >::buffer_type = typename base_t::buffer_type |
Dense per-node bounding-box attribute buffer inherited from the dynamic protocol.
Definition at line 245 of file DynamicTreeAttributeComputer.hpp.
|
inlineexplicit |
Creates a bounding-box computer returning the requested scalar measure.
| measure | Scalar projection materialized from the accumulated bounding-box state. |
Definition at line 524 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Accumulates a child subtree box into its parent subtree box.
| parentId | Identifier of the parent node. |
| childId | Identifier of the child node. |
Implements mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 559 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Updates local boxes after one proper part moves between nodes.
The target box is enlarged eagerly. The source box remains exact unless the removed pixel exhausts one extremum; in that case the source summary is marked dirty and rebuilt lazily.
| targetId | Destination. |
| sourceId | Input. |
| pixelId | Pixel identifier. |
| tree | Tree topology. |
Reimplemented from mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 616 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Updates local boxes after all proper parts move from sourceId to targetId.
| targetId | Destination. |
| sourceId | Input. |
| tree | Tree topology. |
Reimplemented from mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 598 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Clears auxiliary summaries associated with a released node slot.
| nodeId | Dense internal node identifier. |
Reimplemented from mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 684 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Converts the accumulated subtree box into the configured scalar measure.
| nodeId | Dense internal node identifier. |
| buffer | Buffer read or written by the operation. |
Implements mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 569 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Initializes one node's subtree bounding box from its proper part.
| nodeId | Dense internal node identifier. |
| tree | Tree topology. |
Implements mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 548 of file DynamicTreeAttributeComputer.hpp.
|
inlineoverridevirtual |
Resizes public and auxiliary buffers to the current tree slot space.
Auxiliary direct/local and subtree summaries are indexed by the same dense internal node-id space as the public output buffer.
| tree | Tree topology. |
| buffer | Buffer read or written by the operation. |
Reimplemented from mmcfilters::adjust::DynamicTreeAttributeComputer< T >.
Definition at line 535 of file DynamicTreeAttributeComputer.hpp.