Class EquivalentEllipse

java.lang.Object
inra.ijpb.algo.AlgoStub
inra.ijpb.measure.region2d.RegionAnalyzer2D<Ellipse>
inra.ijpb.measure.region2d.EquivalentEllipse
All Implemented Interfaces:
Algo, RegionAnalyzer<Ellipse>

public class EquivalentEllipse
extends RegionAnalyzer2D<Ellipse>
Compute parameters of equivalent ellipse from binar or label images. The equivalent ellipse of a region is computed such that is has same second order moments as the region.
Author:
dlegland
See Also:
EquivalentEllipsoid
  • Constructor Summary

    Constructors
    Constructor Description
    EquivalentEllipse()
    Default constructor.
  • Method Summary

    Modifier and Type Method Description
    Ellipse[] analyzeRegions​(ij.process.ImageProcessor image, int[] labels, ij.measure.Calibration calib)
    Computes the equivalent ellipse of each region within the input label image.
    ij.measure.ResultsTable createTable​(java.util.Map<java.lang.Integer,​Ellipse> map)
    Utility method that transforms the mapping between labels and equivalent ellipses instances into a ResultsTable that can be displayed with ImageJ.
    static Ellipse[] equivalentEllipses​(ij.process.ImageProcessor image, int[] labels, ij.measure.Calibration calib)
    Computes equivalent ellipse of each region in input label image.

    Methods inherited from class inra.ijpb.measure.region2d.RegionAnalyzer2D

    analyzeRegions, analyzeRegions, computeTable

    Methods inherited from class inra.ijpb.algo.AlgoStub

    addAlgoListener, removeAlgoListener

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • EquivalentEllipse

      public EquivalentEllipse()
      Default constructor.
  • Method Details

    • equivalentEllipses

      public static final Ellipse[] equivalentEllipses​(ij.process.ImageProcessor image, int[] labels, ij.measure.Calibration calib)
      Computes equivalent ellipse of each region in input label image.
      Parameters:
      image - the input image containing region labels
      labels - the array of labels within the image
      calib - the calibration of the image
      Returns:
      an array of Ellipse representing the calibrated coordinates of the equivalent ellipse of each region
    • createTable

      public ij.measure.ResultsTable createTable​(java.util.Map<java.lang.Integer,​Ellipse> map)
      Utility method that transforms the mapping between labels and equivalent ellipses instances into a ResultsTable that can be displayed with ImageJ.
      Parameters:
      map - the mapping between labels and Inertia Ellipses
      Returns:
      a ResultsTable that can be displayed with ImageJ.
    • analyzeRegions

      public Ellipse[] analyzeRegions​(ij.process.ImageProcessor image, int[] labels, ij.measure.Calibration calib)
      Computes the equivalent ellipse of each region within the input label image.
      Specified by:
      analyzeRegions in class RegionAnalyzer2D<Ellipse>
      Parameters:
      image - the input image containing region labels
      labels - the array of labels within the image
      calib - the calibration of the image
      Returns:
      an array of Ellipse representing the calibrated coordinates of the inertia ellipse of each region