OpenCV 2.4.8

org.opencv.features2d
Class DescriptorExtractor

java.lang.Object
  extended by org.opencv.features2d.DescriptorExtractor

public class DescriptorExtractor
extends java.lang.Object

Abstract base class for computing descriptors for image keypoints.

class CV_EXPORTS DescriptorExtractor

// C++ code:

public:

virtual ~DescriptorExtractor();

void compute(const Mat& image, vector& keypoints,

Mat& descriptors) const;

void compute(const vector& images, vector >& keypoints,

vector& descriptors) const;

virtual void read(const FileNode&);

virtual void write(FileStorage&) const;

virtual int descriptorSize() const = 0;

virtual int descriptorType() const = 0;

static Ptr create(const string& descriptorExtractorType);

protected:...

};

In this interface, a keypoint descriptor can be represented as a

dense, fixed-dimension vector of a basic type. Most descriptors follow this pattern as it simplifies computing distances between descriptors. Therefore, a collection of descriptors is represented as "Mat", where each row is a keypoint descriptor.

See Also:
org.opencv.features2d.DescriptorExtractor : public Algorithm

Field Summary
static int BRIEF
           
static int BRISK
           
static int FREAK
           
static int OPPONENT_BRIEF
           
static int OPPONENT_BRISK
           
static int OPPONENT_FREAK
           
static int OPPONENT_ORB
           
static int OPPONENT_SIFT
           
static int OPPONENT_SURF
           
static int ORB
           
static int SIFT
           
static int SURF
           
 
Method Summary
 void compute(java.util.List<Mat> images, java.util.List<MatOfKeyPoint> keypoints, java.util.List<Mat> descriptors)
          Computes the descriptors for a set of keypoints detected in an image (first variant) or image set (second variant).
 void compute(Mat image, MatOfKeyPoint keypoints, Mat descriptors)
          Computes the descriptors for a set of keypoints detected in an image (first variant) or image set (second variant).
static DescriptorExtractor create(int extractorType)
          Creates a descriptor extractor by name.
 int descriptorSize()
           
 int descriptorType()
           
 boolean empty()
           
 void read(java.lang.String fileName)
           
 void write(java.lang.String fileName)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

BRIEF

public static final int BRIEF
See Also:
Constant Field Values

BRISK

public static final int BRISK
See Also:
Constant Field Values

FREAK

public static final int FREAK
See Also:
Constant Field Values

OPPONENT_BRIEF

public static final int OPPONENT_BRIEF
See Also:
Constant Field Values

OPPONENT_BRISK

public static final int OPPONENT_BRISK
See Also:
Constant Field Values

OPPONENT_FREAK

public static final int OPPONENT_FREAK
See Also:
Constant Field Values

OPPONENT_ORB

public static final int OPPONENT_ORB
See Also:
Constant Field Values

OPPONENT_SIFT

public static final int OPPONENT_SIFT
See Also:
Constant Field Values

OPPONENT_SURF

public static final int OPPONENT_SURF
See Also:
Constant Field Values

ORB

public static final int ORB
See Also:
Constant Field Values

SIFT

public static final int SIFT
See Also:
Constant Field Values

SURF

public static final int SURF
See Also:
Constant Field Values
Method Detail

compute

public void compute(java.util.List<Mat> images,
                    java.util.List<MatOfKeyPoint> keypoints,
                    java.util.List<Mat> descriptors)

Computes the descriptors for a set of keypoints detected in an image (first variant) or image set (second variant).

Parameters:
images - Image set.
keypoints - Input collection of keypoints. Keypoints for which a descriptor cannot be computed are removed. Sometimes new keypoints can be added, for example: SIFT duplicates keypoint with several dominant orientations (for each orientation).
descriptors - Computed descriptors. In the second variant of the method descriptors[i] are descriptors computed for a keypoints[i]". Row j is the keypoints (or keypoints[i]) is the descriptor for keypoint j"-th keypoint.
See Also:
org.opencv.features2d.DescriptorExtractor.compute

compute

public void compute(Mat image,
                    MatOfKeyPoint keypoints,
                    Mat descriptors)

Computes the descriptors for a set of keypoints detected in an image (first variant) or image set (second variant).

Parameters:
image - Image.
keypoints - Input collection of keypoints. Keypoints for which a descriptor cannot be computed are removed. Sometimes new keypoints can be added, for example: SIFT duplicates keypoint with several dominant orientations (for each orientation).
descriptors - Computed descriptors. In the second variant of the method descriptors[i] are descriptors computed for a keypoints[i]". Row j is the keypoints (or keypoints[i]) is the descriptor for keypoint j"-th keypoint.
See Also:
org.opencv.features2d.DescriptorExtractor.compute

create

public static DescriptorExtractor create(int extractorType)

Creates a descriptor extractor by name.

The current implementation supports the following types of a descriptor extractor:

A combined format is also supported: descriptor extractor adapter name ("Opponent" -- "OpponentColorDescriptorExtractor") + descriptor extractor name (see above), for example: "OpponentSIFT".

Parameters:
extractorType - a extractorType
See Also:
org.opencv.features2d.DescriptorExtractor.create

descriptorSize

public int descriptorSize()

descriptorType

public int descriptorType()

empty

public boolean empty()

read

public void read(java.lang.String fileName)

write

public void write(java.lang.String fileName)

OpenCV 2.4.8 Documentation