Skip to content

Commit

Permalink
Completed wrapping for Python bindings.
Browse files Browse the repository at this point in the history
  • Loading branch information
cr333 committed Feb 18, 2016
1 parent 7b2c6f8 commit e90ae8e
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 18 deletions.
14 changes: 7 additions & 7 deletions modules/aruco/include/opencv2/aruco.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -228,14 +228,14 @@ class CV_EXPORTS_W Board {
public:
// array of object points of all the marker corners in the board
// each marker include its 4 corners, i.e. for M markers, the size is Mx4
std::vector< std::vector< Point3f > > objPoints;
CV_PROP std::vector< std::vector< Point3f > > objPoints;

// the dictionary of markers employed for this board
Ptr<Dictionary> dictionary;
CV_PROP Ptr<Dictionary> dictionary;

// vector of the identifiers of the markers in the board (same size than objPoints)
// The identifiers refers to the board dictionary
std::vector< int > ids;
CV_PROP std::vector< int > ids;
};


Expand All @@ -259,7 +259,7 @@ class CV_EXPORTS_W GridBoard : public Board {
*
* This function return the image of the GridBoard, ready to be printed.
*/
void draw(Size outSize, OutputArray img, int marginSize = 0, int borderBits = 1);
CV_WRAP void draw(Size outSize, OutputArray img, int marginSize = 0, int borderBits = 1);


/**
Expand All @@ -282,17 +282,17 @@ class CV_EXPORTS_W GridBoard : public Board {
/**
*
*/
Size getGridSize() const { return Size(_markersX, _markersY); }
CV_WRAP Size getGridSize() const { return Size(_markersX, _markersY); }

/**
*
*/
float getMarkerLength() const { return _markerLength; }
CV_WRAP float getMarkerLength() const { return _markerLength; }

/**
*
*/
float getMarkerSeparation() const { return _markerSeparation; }
CV_WRAP float getMarkerSeparation() const { return _markerSeparation; }


private:
Expand Down
14 changes: 7 additions & 7 deletions modules/aruco/include/opencv2/aruco/charuco.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,11 @@ class CV_EXPORTS_W CharucoBoard : public Board {

public:
// vector of chessboard 3D corners precalculated
std::vector< Point3f > chessboardCorners;
CV_PROP std::vector< Point3f > chessboardCorners;

// for each charuco corner, nearest marker id and nearest marker corner id of each marker
std::vector< std::vector< int > > nearestMarkerIdx;
std::vector< std::vector< int > > nearestMarkerCorners;
CV_PROP std::vector< std::vector< int > > nearestMarkerIdx;
CV_PROP std::vector< std::vector< int > > nearestMarkerCorners;

/**
* @brief Draw a ChArUco board
Expand All @@ -80,7 +80,7 @@ class CV_EXPORTS_W CharucoBoard : public Board {
*
* This function return the image of the ChArUco board, ready to be printed.
*/
void draw(Size outSize, OutputArray img, int marginSize = 0, int borderBits = 1);
CV_WRAP void draw(Size outSize, OutputArray img, int marginSize = 0, int borderBits = 1);


/**
Expand All @@ -103,17 +103,17 @@ class CV_EXPORTS_W CharucoBoard : public Board {
/**
*
*/
Size getChessboardSize() const { return Size(_squaresX, _squaresY); }
CV_WRAP Size getChessboardSize() const { return Size(_squaresX, _squaresY); }

/**
*
*/
float getSquareLength() const { return _squareLength; }
CV_WRAP float getSquareLength() const { return _squareLength; }

/**
*
*/
float getMarkerLength() const { return _markerLength; }
CV_WRAP float getMarkerLength() const { return _markerLength; }

private:
void _getNearestMarkerCorners();
Expand Down
8 changes: 4 additions & 4 deletions modules/aruco/include/opencv2/aruco/dictionary.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@ namespace aruco {
class CV_EXPORTS_W Dictionary {

public:
CV_PROP_RW Mat bytesList; // marker code information
CV_PROP_RW int markerSize; // number of bits per dimension
CV_PROP_RW int maxCorrectionBits; // maximum number of bits that can be corrected
CV_PROP Mat bytesList; // marker code information
CV_PROP int markerSize; // number of bits per dimension
CV_PROP int maxCorrectionBits; // maximum number of bits that can be corrected


/**
Expand Down Expand Up @@ -114,7 +114,7 @@ class CV_EXPORTS_W Dictionary {
/**
* @brief Draw a canonical marker image
*/
void drawMarker(int id, int sidePixels, OutputArray _img, int borderBits = 1) const;
CV_WRAP void drawMarker(int id, int sidePixels, OutputArray _img, int borderBits = 1) const;


/**
Expand Down

0 comments on commit e90ae8e

Please sign in to comment.