Into

Modules

Documentation

classPiiImage::ObjectSizeLimiter

#include <PiiLabeling.h>

An object size limiter for labelImage().

Description

This class counts the occurrences of each label and removes all objects smaller than or equal to than the specified threshold

Constructors and destructor

(
  • int sizeThreshold
)

Create a size limiter that only accepts objects larger than sizeThreshold.

Public member functions

void

Extend the list of stored labels by one.

void
(
  • int label
)

The labelImage() function found a pixel it labeled as label.

void
( )

Retains all labels with more than sizeThreshold histogram entries.

void
( )

Called by labelImage() to store the intial set of labels.

Function details

  • ObjectSizeLimiter

    (
    • int sizeThreshold
    )
    [inline]

    Create a size limiter that only accepts objects larger than sizeThreshold.

  • void addLabel

    ()
    [inline]

    Extend the list of stored labels by one.

  • void addPixel

    (
    • int label
    )
    [inline]

    The labelImage() function found a pixel it labeled as label.

    Increases the label's histogram.

  • void limitLabels

    ( )
    [inline]

    Retains all labels with more than sizeThreshold histogram entries.

    Sets all other labels to zero.

  • void setInitialLabels

    ( )
    [inline]

    Called by labelImage() to store the intial set of labels.

    The labels are just cloned and stored.

Notes (0)

Add a note

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