org.opencv.features2d

## Class MSER

- java.lang.Object
- - org.opencv.core.Algorithm
  - - org.opencv.features2d.Feature2D
    - - org.opencv.features2d.MSER

-     public class MSER
      extends Feature2D

  Maximally stable extremal region extractor The class encapsulates all the parameters of the %MSER extraction algorithm (see [wiki article](http://en.wikipedia.org/wiki/Maximally_stable_extremal_regions)).
  - there are two different implementation of %MSER: one for grey image, one for color image
  - the grey image algorithm is taken from: CITE: nister2008linear ; the paper claims to be faster than union-find method; it actually get 1.5~2m/s on my centrino L7200 1.2GHz laptop.
  - the color image algorithm is taken from: CITE: forssen2007maximally ; it should be much slower than grey image method ( 3~4 times ); the chi_table.h file is taken directly from paper's source code which is distributed under GPL.
  - (Python) A complete example showing the use of the %MSER detector can be found at samples/python/mser.py

- - ### Field Summary

    - ### Fields inherited from class org.opencv.core.Algorithm

      `nativeObj`

  - ### Constructor Summary

    Constructors
    Modifier | Constructor and Description
    --- | ---
    `protected` | `MSER(long addr)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static MSER` | `__fromPtr__(long addr)`
    `static MSER` | `create()` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area, double _max_variation)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area, double _max_variation, double _min_diversity)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area, double _max_variation, double _min_diversity, int _max_evolution)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area, double _max_variation, double _min_diversity, int _max_evolution, double _area_threshold)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area, double _max_variation, double _min_diversity, int _max_evolution, double _area_threshold, double _min_margin)` Full consturctor for %MSER detector
    `static MSER` | `create(int _delta, int _min_area, int _max_area, double _max_variation, double _min_diversity, int _max_evolution, double _area_threshold, double _min_margin, int _edge_blur_size)` Full consturctor for %MSER detector
    `void` | `detectRegions(Mat image, List<MatOfPoint> msers, MatOfRect bboxes)` Detect %MSER regions
    `protected void` | `finalize()`
    `String` | `getDefaultName()` Returns the algorithm string identifier.
    `int` | `getDelta()`
    `int` | `getMaxArea()`
    `int` | `getMinArea()`
    `boolean` | `getPass2Only()`
    `void` | `setDelta(int delta)`
    `void` | `setMaxArea(int maxArea)`
    `void` | `setMinArea(int minArea)`
    `void` | `setPass2Only(boolean f)`

    - ### Methods inherited from class org.opencv.features2d.Feature2D

      `compute, compute, defaultNorm, descriptorSize, descriptorType, detect, detect, detect, detect, detectAndCompute, detectAndCompute, empty, read, write`

    - ### Methods inherited from class org.opencv.core.Algorithm

      `clear, getNativeObjAddr, save`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### MSER

          protected MSER(long addr)

  - ### Method Detail

    - #### __fromPtr__

          public static MSER __fromPtr__(long addr)

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area,
                                    double _max_variation,
                                    double _min_diversity,
                                    int _max_evolution,
                                    double _area_threshold,
                                    double _min_margin,
                                    int _edge_blur_size)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
        `_max_variation` - prune the area have similar size to its children
        `_min_diversity` - for color image, trace back to cut off mser with diversity less than min_diversity
        `_max_evolution` - for color image, the evolution steps
        `_area_threshold` - for color image, the area threshold to cause re-initialize
        `_min_margin` - for color image, ignore too small margin
        `_edge_blur_size` - for color image, the aperture size for edge blur
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area,
                                    double _max_variation,
                                    double _min_diversity,
                                    int _max_evolution,
                                    double _area_threshold,
                                    double _min_margin)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
        `_max_variation` - prune the area have similar size to its children
        `_min_diversity` - for color image, trace back to cut off mser with diversity less than min_diversity
        `_max_evolution` - for color image, the evolution steps
        `_area_threshold` - for color image, the area threshold to cause re-initialize
        `_min_margin` - for color image, ignore too small margin
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area,
                                    double _max_variation,
                                    double _min_diversity,
                                    int _max_evolution,
                                    double _area_threshold)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
        `_max_variation` - prune the area have similar size to its children
        `_min_diversity` - for color image, trace back to cut off mser with diversity less than min_diversity
        `_max_evolution` - for color image, the evolution steps
        `_area_threshold` - for color image, the area threshold to cause re-initialize
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area,
                                    double _max_variation,
                                    double _min_diversity,
                                    int _max_evolution)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
        `_max_variation` - prune the area have similar size to its children
        `_min_diversity` - for color image, trace back to cut off mser with diversity less than min_diversity
        `_max_evolution` - for color image, the evolution steps
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area,
                                    double _max_variation,
                                    double _min_diversity)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
        `_max_variation` - prune the area have similar size to its children
        `_min_diversity` - for color image, trace back to cut off mser with diversity less than min_diversity
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area,
                                    double _max_variation)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
        `_max_variation` - prune the area have similar size to its children
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area,
                                    int _max_area)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
        `_max_area` - prune the area which bigger than maxArea
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta,
                                    int _min_area)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
        `_min_area` - prune the area which smaller than minArea
      Returns:
        automatically generated

    - #### create

          public static MSER create(int _delta)

      Full consturctor for %MSER detector
      Parameters:
        `_delta` - it compares \((size_{i}-size_{i-delta})/size_{i-delta}\)
      Returns:
        automatically generated

    - #### create

          public static MSER create()

      Full consturctor for %MSER detector
      Returns:
        automatically generated

    - #### getDefaultName

          public String getDefaultName()

      Description copied from class: `Algorithm`
      Returns the algorithm string identifier. This string is used as top level xml/yml node tag when the object is saved to a file or string.
      Overrides:
        `getDefaultName` in class `Feature2D`
      Returns:
        automatically generated

    - #### getPass2Only

          public boolean getPass2Only()

    - #### getDelta

          public int getDelta()

    - #### getMaxArea

          public int getMaxArea()

    - #### getMinArea

          public int getMinArea()

    - #### detectRegions

          public void detectRegions(Mat image,
                                    List<MatOfPoint> msers,
                                    MatOfRect bboxes)

      Detect %MSER regions
      Parameters:
        `image` - input image (8UC1, 8UC3 or 8UC4, must be greater or equal than 3x3)
        `msers` - resulting list of point sets
        `bboxes` - resulting bounding boxes

    - #### setDelta

          public void setDelta(int delta)

    - #### setMaxArea

          public void setMaxArea(int maxArea)

    - #### setMinArea

          public void setMinArea(int minArea)

    - #### setPass2Only

          public void setPass2Only(boolean f)

    - #### finalize

          protected void finalize()
                           throws Throwable

      Overrides:
        `finalize` in class `Feature2D`
      Throws:
        `Throwable`

Generated on Wed Oct 9 2019 16:55:37 UTC / OpenCV 3.4.8