Into

Modules

Documentation

classPiiObjectPropertyExtractor

#include <PiiObjectPropertyExtractor.h>

Calculates geometric properties for labeled objects.

Inherits PiiDefaultOperation

Description

Inputs

imagea labeled image. Each object in the image must have a unique integer label that distinguishes it from others. (any integer-valued matrix)
labelsthe number of distinct objects. This input is optional. (int)

Outputs

areasthe number of pixels on each object. PiiMatrix<int>(N,1).
centroidsthe center-of-mass point (x,y) for each object. PiiMatrix<int>(N,2).
boundingboxesThe bounding boxes of each object (x,y,width,height). PiiMatrix<int>(N,4).

Constructors and destructor

Protected member functions

virtual void

Executes one round of processing.

Function details

  • PiiObjectPropertyExtractor

    ()
  • virtual void process

    ()
    [protected, virtual]

    Executes one round of processing.

    This function is invoked by the processor if the necessary preconditions for a new processing round are met. This function does all the necessary calculations to create output objects and sends them to output sockets.

    Calls to process(), syncEvent(), and setProperty() are synchronized and cannot occur simultaneously. PiiDefaultOperation ensures this by locking processLock() for reading before calling process().

    Note: With time-consuming operations, one should occasionally check that the operation hasn't been interrupted, i.e. that state() returns Running.

    Exceptions
    PiiExecutionException

    whenever an unrecoverable error occurs during a processing round, the operation is interrupted, or finishes execution due to end of input data.

    Reimplemented from PiiDefaultOperation.

Notes (0)

Add a note

Not a single note added yet. Be the first, add yours.