Update doCornerRefinement() parameter to cornerRefinementMethod().

pull/1190/head
catree 8 years ago
parent 2abf45d1ee
commit dc8e29a0ad
  1. 2
      modules/aruco/samples/detector_params.yml
  2. 8
      modules/aruco/tutorials/aruco_detection/aruco_detection.markdown
  3. 4
      modules/aruco/tutorials/charuco_detection/charuco_detection.markdown

@ -12,7 +12,7 @@ minCornerDistance: 10.0
minDistanceToBorder: 3
minMarkerDistance: 10.0
minMarkerDistanceRate: 0.05
doCornerRefinement: false
cornerRefinementMethod: 0
cornerRefinementWinSize: 5
cornerRefinementMaxIterations: 30
cornerRefinementMinAccuracy: 0.1

@ -702,23 +702,23 @@ Default value: 0.6
#### Corner Refinement
After markers have been detected and identified, the last step is performing subpixel refinement
in the corner positions (see OpenCV ```cornerSubPix()```)
in the corner positions (see OpenCV ```cornerSubPix()``` and ```cv::aruco::CornerRefineMethod```)
Note that this step is optional and it only makes sense if the position of the marker corners have to
be accurate, for instance for pose estimation. It is usually a time consuming step and it is disabled by default.
- ```bool doCornerRefinement```
- ```int cornerRefinementMethod```
This parameter determines if the corner subpixel process is performed or not. It can be disabled
if accurate corners are not necessary.
Default value: false.
Default value: ```CORNER_REFINE_NONE```.
- ```int cornerRefinementWinSize```
This parameter determines the window size of the subpixel refinement process.
High values can produce that close image corners are included in the window region, so that the
High values can produce the effect that close image corners are included in the window region, so that the
marker corner moves to a different and wrong location during the process. Furthermore
it can affect to performance.

@ -142,7 +142,7 @@ are optional. A similar example without these parameters would be:
std::vector<int> markerIds;
std::vector<std::vector<cv::Point2f>> markerCorners;
cv::Ptr<cv::aruco::DetectorParameters> params;
params->doCornerRefinement = false;
params->cornerRefinementMethod = cv::aruco::CORNER_REFINE_NONE;
cv::aruco::detectMarkers(inputImage, board.dictionary, markerCorners, markerIds, params);
// if at least one marker detected
@ -207,7 +207,7 @@ Finally, this is a full example of ChArUco detection (without using calibration
cv::Ptr<cv::aruco::CharucoBoard> board = cv::aruco::CharucoBoard::create(5, 7, 0.04, 0.02, dictionary);
cv::Ptr<cv::aruco::DetectorParameters> params;
params->doCornerRefinement = false;
params->cornerRefinementMethod = cv::aruco::CORNER_REFINE_NONE;
while (inputVideo.grab()) {
cv::Mat image, imageCopy;

Loading…
Cancel
Save