Commit Graph

1203 Commits

Author SHA1 Message Date
Alexander Alekhin
2268ed1b6e Merge pull request #12948 from catree:add_drawFrameAxes 2018-10-30 13:33:01 +00:00
Wenfeng CAI
c9abb823a7 Fix signature of static collectCalibrationData()
This is a fix to the signature of static function
collectCalibrationData() and clean-up for #12772. Since fallback scheme
in calibration method selection is not used anymore. As an input
parameter, iFixedPoint should be passed by value according to the OpenCV
coding style guide.
2018-10-29 10:19:02 +08:00
catree
d37164bab6 Fix distortion figure in calib3d. Positive radial distortion corresponds to pincushion distortion and negative to barrel distortion. Add another figure that illustrates the influence of k1 in the distortion effect. 2018-10-26 20:27:37 +02:00
kamino410
3972c526ce fix document about camera distortion parameters 2018-10-26 19:55:46 +09:00
Wenfeng CAI
31be03a805 Merge pull request #12772 from xoox:calib-release-object
More accurate pinhole camera calibration with imperfect planar target (#12772)
43 commits:

* Add derivatives with respect to object points

Add an output parameter to calculate derivatives of image points with
respect to 3D coordinates of object points. The output jacobian matrix
is a 2Nx3N matrix where N is the number of points.

This commit introduces incompatibility to old function signature.

* Set zero for dpdo matrix before using

dpdo is a sparse matrix with only non-zero value close to major
diagonal. Set it to zero because only elements near major diagonal are
computed.

* Add jacobian columns to projectPoints()

The output jacobian matrix of derivatives with respect to coordinates of
3D object points are added. This might break callers who assume the
columns of jacobian matrix.

* Adapt test code to updated project functions

The test cases for projectPoints() and cvProjectPoints2() are updated to
fit new function signatures.

* Add accuracy test code for dpdo

* Add badarg test for dpdo

* Add new enum item for new calibration method

CALIB_RELEASE_OBJECT is used to whether to release 3D coordinates of
object points. The method was proposed in: K. H. Strobl and G. Hirzinger.
"More Accurate Pinhole Camera Calibration with Imperfect Planar Target".
In Proceedings of the IEEE International Conference on Computer Vision
(ICCV 2011), 1st IEEE Workshop on Challenges and Opportunities in Robot
Perception, Barcelona, Spain, pp. 1068-1075, November 2011.

* Add releasing object method into internal function

It's a simple extension of the standard calibration scheme. We choose to
fix the first and last object point and a user-selected fixed point.

* Add interfaces for extended calibration method

* Refine document for calibrateCamera()

When releasing object points, only the z coordinates of the
objectPoints[0].back is fixed.

* Add link to strobl2011iccv paper

* Improve documentation for calibrateCamera()

* Add implementations of wrapping calibrateCamera()

* Add checking for params of new calibration method

If input parameters are not qualified, then fall back to standard
calibration method.

* Add camera calibration method of releasing object

The current implementation is equal to or better than
https://github.com/xoox/calibrel

* Update doc for CALIB_RELEASE_OBJECT

CALIB_USE_QR or CALIB_USE_LU could be used for faster calibration with
potentially less precise and less stable in some rare cases.

* Add RELEASE_OBJECT calibration to tutorial code

To select the calibration method of releasing object points, a command
line parameter `-d=<number>` should be provided.

* Update tutorial doc for camera_calibration

If the method of releasing object points is merged into OpenCV. It will
be expected to be firstly released in 4.1, I think.

* Reduce epsilon for cornerSubPix()

Epsilon of 0.1 is a bigger one. Preciser corner positions are required
with calibration method of releasing object.

* Refine camera calibration tutorial

The hypothesis coordinates are used to indicate which distance must be
measured between two specified object points.

* Update sample calibration code method selection

Similar to camera_calibration tutorial application, a command line
argument `-dt=<number>` is used to select the calibration method.

* Add guard to flags of cvCalibrateCamera2()

cvCalibrateCamera2() doesn't accept CALIB_RELEASE_OBJECT unless overload
interface is added in the future.

* Simplify fallback when iFixedPoint is out of range

* Refactor projectPoints() to keep compatibilities

* Fix arg string "Bad rvecs header"

* Read calibration flags from test data files

Instead of being hard coded into source file, the calibration flags will
be read from test data files.
opencv_extra/testdata/cv/cameracalibration/calib?.dat must be sync with
the test code.

* Add new C interface of cvCalibrateCamera4()

With this new added C interface, the extended calibration method with
CALIB_RELEASE_OBJECT can be called by C API.

* Add regression test of extended calibration method

It has been tested with new added test data in xoox:calib-release-object
branch of opencv_extra.

* Fix assertion in test_cameracalibration.cpp

The total number of refined 3D object coordinates is checked.

* Add checker for iFixedPoint in cvCalibrateCamera4

If iFixedPoint is out of rational range, fall back to standard method.

* Fix documentation for overloaded calibrateCamera()

* Remove calibration flag of CALIB_RELEASE_OBJECT

The method selection is based on the range of the index of fixed point.
For minus values, standard calibration method will be chosen.  Values in
a rational range will make the object-releasing calibration method
selected.

* Use new interfaces instead of function overload

Existing interfaces are preserved and new interfaces are added. Since
most part of the code base are shared, calibrateCamera() is now a
wrapper function of calibrateCameraRO().

* Fix exported name of calibrateCameraRO()

* Update documentation for calibrateCameraRO()

The circumstances where this method is mostly helpful are described.

* Add note on the rigidity of the calibration target

* Update documentation for calibrateCameraRO()

It is clarified that iFixedPoint is used as a switch to select
calibration method. If input data are not qualified, exceptions will be
thrown instead of fallback scheme.

* Clarify iFixedPoint as switch and remove fallback

iFixedPoint is now used as a switch for calibration method selection. No
fallback scheme is utilized anymore. If the input data are not
qualified, exceptions will be thrown.

* Add badarg test for object-releasing method

* Fix document format of sample list

List items of same level should be indented the same way. Otherwise they
will be formatted as nested lists by Doxygen.

* Add brief intro for objectPoints and imagePoints

* Sync tutorial to sample calibration code

* Update tutorial compatibility version to 4.0
2018-10-25 19:38:55 +03:00
catree
644846c702 Add a function that draws frame axes. Useful for debugging purpose and to check the correctness of the output of a pose estimation method. 2018-10-25 18:38:19 +02:00
Maksim Shabunin
0ccd810738 Fixed several issues found by static analysis 2018-10-25 10:45:59 +03:00
Alexander Alekhin
edacd91a27 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-10-15 20:15:42 +00:00
tompollok
0b77600718 change area() emptiness checks to empty() 2018-10-13 21:35:10 +02:00
Alexander Alekhin
dada5a422d Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-10-09 21:20:15 +00:00
Alexander Alekhin
8f1f4273a2 calib3d: move undistort files from imgproc 2018-10-05 07:52:21 +00:00
Apoorv Goel
0ffc186680 Merge pull request #12731 from UnderscoreAsterisk:fix-12012
* fix #12012

* Replace CV_StsBadFlag with Error::StsBadFlag
2018-10-03 15:50:04 +03:00
Alexander Alekhin
e4f71994c2 calib3d: findChessboardCornersSB() minor updates
- avoid updating of input image during equalizeHist() call
- avoid for() with double variable (use 'int' instead)
- more CV_Check*() macros
- use Mat_<T>, Matx
- static for local variables
2018-09-27 15:38:01 +03:00
Menghui Xie
f0d277e452 M_PI changed to CV_PI (#12645)
* M_PI changed to CV_PI

* M_PI changed to CV_PI

* M_PI changed to CV_PI
2018-09-26 16:05:02 +03:00
Alexander Duda
8811dabbac Merge pull request #12615 from D-Alex:master
findChessboardCornersSB: speed improvements (#12615)

* chessboard: fix do not modify const image

* chessboard: speed up scale space using parallel_for

* chessboard: small improvements

* chessboard: speed up board growing using parallel_for

* chessboard: add flags for tuning detection

* chessboard: fix compiler warnings

* chessborad: change flag name to CALIB_CB_EXHAUSTIVE

This also fixes a typo

* chessboard: fix const ref + remove to_string
2018-09-25 17:06:46 +03:00
Wenfeng CAI
fce75cd858 Fix failure to request stddev of non-intrinsics
Before this fix, the code would fail if only standard deviations of
extrinsic parameters are requested. While standard deviations matrix
should be computed if any set of standard deviations is requested. A
variable is added to represent this case.
2018-09-19 12:27:07 +08:00
Alexander Alekhin
38de2a8754 calib3d: fix build warnings 2018-09-17 22:16:31 +00:00
Alexander Alekhin
808ba552c5 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-09-14 23:44:35 +00:00
Hamdi Sahloul
5d54def264 Add semicolons after CV_INSTRUMENT macros 2018-09-14 06:45:31 +09:00
Alexander Duda
a024593fa6 Merge pull request #12147 from D-Alex:master
* add new chessboard detector

The chessboar detector is based on the paper.
Accurate Detection and Localization of Checkerboard Corners for
Calibration Alexander Duda, Udo Frese
British Machine Vision Conference, o.A., 2018.

It utilizes point symmetry of checkerboard corners in combination with a
localized Radon transform approximated by box filters to achieve high
performance even on large images. Here, tests have shown that the
ability to localize checkerboard corners is close to the theoretical
limit of 1/100 of a pixel while being considerably less sensitive
to image noise than standard methods.

* chessboard: add reference to bibtex file

* chessboard: add dependency to opencv_flann

* fix: test chesscorners. It is valid to return an empty list

In case no chessboard was detected it should be valid for the detector
to return an empty list.

For simplifcation, it should be allowed to return any number of corners
if they are flagged as not found.

* fix: opencv.bib remove empty lines

* fix: doc findChessboardCorners replace cvSize with cv::Size

* chessboard tests: factor out logic selecting detector

* chessboard: add unit test for findChessboardCorners2

This is includes a new chessboard generator which supports subpix
corners with high accuracy by wrapping an optimal chessboard using
wrapPerspective.

* fix: chessboard unit test - overwrite of default parameter flag of findCirclesGrid

* chessboard: remove trailing whitespace

* chessboard: fix debug drawing

* chessboard: fix some issues during code review

* chessboard: normalize asymmetric chessboard

* chessboard: fix float double warning

* remove trailing whitespace

* chessboards: fix compiler warnings

* chessboards: fix compiler warnings

* checkerboard: some performance improvements

* chessboard: remove NULL macros for language bindinges from internal headers

* chessboard: shorten license terms

* chessboard: remove unused internal method

* chessboard: set helper functions to static

* chessboard: fix normalizePoints1D using unshifted points

* chessboard: remove wrongly copied text

* chessboard: use CV_CheckTypeEQ macro

* chessboard: comment all NaN checks

* chessboard: use consistent color conversion

* chessboard: use CheckChannelEQ macro

* chessboard: assume gray color image for internal methods

* chessboard: use std::swap

* chessboard: use Mat.dataend

* chessboard: fix compiler warnings

* chessboard: replace some checks witch CV_CHECK macro

* chessboard: fix comparison function for partial sort

* chessboard: small cleanup

* chessboard: use short license header

* chessboard: rename findChessboard2 to findChessboardSB

* chessboard: fix type in unit test
2018-09-13 15:43:04 +03:00
Hamdi Sahloul
03b3be0f51 MSVC: Slience external/meaningless warnings 2018-09-12 20:02:13 +09:00
Alexander Alekhin
dca657a2fd Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-09-10 00:10:21 +03:00
Hamdi Sahloul
a39e0daacf Utilize CV_UNUSED macro 2018-09-07 20:33:52 +09:00
Alexander Alekhin
73bfe68821 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-09-07 12:40:27 +03:00
Alexander Alekhin
f1f15841d7 Merge pull request #11630 from alalek:c_api_eliminate_constructors 2018-09-06 20:07:16 +00:00
Vadim Pisarevsky
54279523a3 Merge pull request #12437 from vpisarev:avx2_fixes
* trying to fix the custom AVX2 builder test failures (false alarms)

* fixed compile error with CPU_BASELINE=AVX2 on x86; raised tolerance thresholds in a couple of tests

* fixed compile error with CPU_BASELINE=AVX2 on x86; raised tolerance thresholds in a couple of tests

* fixed compile error with CPU_BASELINE=AVX2 on x86; raised tolerance thresholds in a couple of tests

* seemingly disabled false alarm warning in surf.cpp; increased tolerance thresholds in the tests for SolvePnP and in DNN/ENet
2018-09-06 18:56:55 +03:00
Alexander Alekhin
8a3c394d6a don't use constructors for C API structures 2018-09-06 14:34:16 +03:00
Alexander Alekhin
d74b98c3d9 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-09-04 18:39:03 +00:00
Alexander Alekhin
701760dbeb calib3d: use Mat::reserveBuffer() instead of .create()
to allocate memory >2Gb
2018-09-01 13:18:08 +00:00
Jakub Golinowski
9f1218b00b Merge pull request #11897 from Jakub-Golinowski:hpx_backend
* Add HPX backend for OpenCV implementation
Adds hpx backend for cv::parallel_for_() calls respecting the nstripes chunking parameter. C++ code for the backend is added to modules/core/parallel.cpp. Also, the necessary changes to cmake files are introduced.
Backend can operate in 2 versions (selectable by cmake build option WITH_HPX_STARTSTOP): hpx (runtime always on) and hpx_startstop (start and stop the backend for each cv::parallel_for_() call)

* WIP: Conditionally include hpx_main.hpp to tests in core module
Header hpx_main.hpp is included to both core/perf/perf_main.cpp and core/test/test_main.cpp.
The changes to cmake files for linking hpx library to above mentioned test executalbles are proposed but have issues.

* Add coditional iclusion of hpx_main.hpp to cpp cpu modules

* Remove start/stop version of hpx backend
2018-08-31 16:23:26 +03:00
Alexander Alekhin
7d4bb9428b Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-08-20 19:30:18 +03:00
Alexander Alekhin
31fef14d76 Merge pull request #12136 from sturkmen72:update_documentation 2018-08-17 14:02:20 +00:00
Suleyman TURKMEN
c61bc3a0cb Update documentation and samples 2018-08-17 14:21:29 +03:00
Alexander Alekhin
b996b618e0 Merge pull request #12228 from tomoaki0705:fixTypoCalib3d 2018-08-16 12:29:10 +00:00
Tomoaki Teshima
f0c46a4c74 fix typo 2018-08-16 19:11:40 +09:00
Alexander Alekhin
4eb2966559 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-08-07 20:12:10 +03:00
luz.paz
2003eb1b9b Misc. typos
Found via `codespell -q 3 -I ../opencv-whitelist.txt --skip="./3rdparty"`
2018-07-31 18:44:23 +03:00
Alexander Alekhin
9787ab598b Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-07-24 22:48:54 +03:00
Maksim Shabunin
cbb1e867e5 More issues found by static analysis 2018-07-24 16:04:42 +03:00
Alexander Alekhin
4560909a5e Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-07-17 19:27:48 +03:00
Alexander Alekhin
f3ee07ca11 Merge pull request #11986 from alalek:build_eliminate_gcc8_warnings 2018-07-17 15:41:36 +00:00
Maksim Shabunin
1da46fe6fb Fixed issues found by static analysis (mostly DBZ) 2018-07-17 16:14:54 +03:00
Dmitry Kurtaev
f38808a39f Add Java overloads for each default argument (#11940)
* Add Java overloads for each default argument

* Add "fisheye_" prefix for cv::fisheye:: functions and enums
2018-07-17 13:41:46 +03:00
Kuang Fangjun
84f2f37680 remove a useless statement. 2018-07-16 22:44:11 +08:00
Alexander Alekhin
d5951bc033 build: eliminate GCC8 warnings 2018-07-16 17:24:12 +03:00
Alexander Alekhin
2da96be217 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-07-09 19:44:51 +03:00
Alexander Alekhin
c7fc563dc0 calib3d: chessboard detector - replace OpenCV C API 2018-07-05 13:09:10 +03:00
Alexander Alekhin
b09a4a98d4 opencv: Use cv::AutoBuffer<>::data() 2018-07-04 19:11:29 +03:00
Alexander Alekhin
3165baa1f1 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-07-02 14:58:29 +03:00
Vadim Pisarevsky
75ee536d6d
Filter homography decomp: updated PR #7153 (#11846)
* Add functionality to filter homography decompositions

* documentation + small refactor

* fix comparing int to size_t (compiler warning)

* fix whitespace issues

* clarification of function return values in documentation

* refactor of function parameters and change in loop nesting

* cleanup useless .h, fix size_t to int compare, small refactor

* fix documentation and whitespace

* change output from return value to outputarray parameter

* update function docs to reflect changes in parameters

* whitespace

* failing test

* fixed warnings related to extended initialisers and improper types

* initialize vectors from arrays

* initialize vectors from arrays part 2

* fix whitespace

* fix trailing whitespace

* Include <inttypes.h> in test_filter_homography_decomp.cpp, should fix 'uint8_t' : undeclared identifier error

* updated the test (made it shorter and providing better diagnostic) and significantly improved implementation (get rid of heavy repeated and/or unnecessary operations)

* fixed compile warning; removed trailing whitespace
2018-06-27 16:47:35 +03:00
Alexander Alekhin
45dd575ed2 Merge remote-tracking branch 'upstream/3.4' into merge-3.4
Revert "documentation: avoid links to 'master' branch from 3.4 maintenance branch"
This reverts commit 9ba9358ecb.

Revert "documentation: avoid links to 'master' branch from 3.4 maintenance branch (2)"
This reverts commit f185802489.
2018-06-04 19:26:10 +03:00
Rostislav Vasilikhin
fc35c77f00 Merge pull request #11610 from savuor:fix/stereobm_simd_fixed_float
* StereoBM: fixed SIMD processing for fixed-type output arrays

* changed norm type and threshold, added assertion

* fixed disp_shift
2018-06-04 13:03:12 +00:00
Alexander Alekhin
40a61ec64e Merge pull request #11647 from sanchom:3.4 2018-06-02 20:52:17 +00:00
Sancho McCann
dbab7ecac8 Refactored out a dead code path. 2018-05-31 21:09:26 +00:00
Alexander Alekhin
1822e85f4a Merge pull request #11642 from alalek:calib3d_chess_board_avoid_clone 2018-05-31 19:17:48 +00:00
Vadim Pisarevsky
7d19bd6c19 Merge pull request #11634 from vpisarev:empty_mat_with_types_2
fixes handling of empty matrices in some functions (#11634)

* a part of PR #11416 by Yuki Takehara

* moved the empty mat check in Mat::copyTo()

* fixed some test failures
2018-05-31 16:36:39 +00:00
Alexander Alekhin
1bc96e3ed0 calib3d: cv::findContours() doesn't require to clone input 2018-05-31 19:34:23 +03:00
Alexander Alekhin
d70e01b635 calib3d: chess board - replace to cv::findContours() 2018-05-29 14:16:20 +00:00
Alexander Alekhin
58d28061a4 Merge pull request #11591 from alalek:calib3d_chessboard_fix3 2018-05-28 12:48:11 +00:00
Alexander Alekhin
faae5edf72 Merge pull request #11590 from alalek:calib3d_chessboard_fix2 2018-05-28 12:44:46 +00:00
Alexander Alekhin
0f298a4203 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-05-28 11:22:55 +00:00
Alexander Alekhin
29421d7def Merge pull request #11589 from alalek:calib3d_chessboard_fix 2018-05-28 10:13:43 +00:00
Alexander Alekhin
f3cbb0f941 calib3d: chess board - perform full range (with 0) histogram smooth 2018-05-25 15:35:36 +03:00
Alexander Alekhin
ad57750d25 calib3d: chess board - properly detect/handle iCntMaxima=0 case 2018-05-25 15:32:07 +03:00
Alexander Alekhin
1dfc742f27 calib3d: chess board - avoid image modification via cvFindContours 2018-05-25 15:01:34 +03:00
Michael Firman
e8cb67572a Bugfix to allow adjust3rdMatrix to be run 2018-05-23 16:03:21 +01:00
Alexander Alekhin
cd2b188c9a Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2018-04-24 18:13:06 +03:00
Alexander Alekhin
6b581c4e51 build: unreachable code after CV_Error() (part 2) 2018-04-24 16:03:40 +03:00
Alexander Alekhin
5b17a60dde next: drop HAVE_TEGRA_OPTIMIZATION/TADP 2018-04-10 18:09:54 +03:00
Alexander Alekhin
ca922443db next(calib3d): eliminate CirclesGridFinderParameters2 2018-04-10 18:09:54 +03:00
Alexander Alekhin
98c8584b88 next: drop CV_CXX11 conditions
define itself is still here for compatibility
2018-04-10 18:09:54 +03:00
Alexander Alekhin
2b2fa58f97 next: drop DISABLE_OPENCV_24_COMPATIBILITY 2018-04-10 18:09:53 +03:00
Alexander Alekhin
7f63b31ca8 avoid calling of setNumThreads() to respect user settings 2018-03-29 13:04:26 +03:00
Alexander Alekhin
bdbd0129af calib3d: apply CV_OVERRIDE/CV_FINAL 2018-03-28 17:57:59 +03:00
Alexander Alekhin
7ee217285b Merge pull request #11089 from terfendail:stereocalibrate_f32 2018-03-27 13:08:06 +00:00
Tomoaki Teshima
08e0c69dbf apply the workaround to correct range 2018-03-22 18:28:47 +09:00
Vitaly Tuzov
7afaaef0eb Allow CV_32FC3 objPoints in cv::fisheye::stereoCalibrate 2018-03-16 13:05:40 +03:00
Tomoaki Teshima
7fd53f6ca2 avoid clang weird behavior in calib3d
* add ifdef to apply on specific situation
2018-03-13 21:51:20 +09:00
PalkoNazar
470d34ddbb make tmpRow proper size before copyTo to avoid reallocated tmpCol (#10860)
* make tmpRow proper size before copyTo to avoid reallocated tmpCol

* do the transposition without creating temporary array; replace TAB with spaces.

* revert the previous commit
2018-02-20 16:55:25 +03:00
Alexander Alekhin
c020a7bb67 build: portable integer types 2018-02-15 23:43:02 +03:00
Alexander Alekhin
e268fdc0ed Merge pull request #10793 from denmatfoton:master 2018-02-15 15:52:52 +00:00
Alexander Alekhin
f378f1d585 calib3d: add regression test for stereoCalibrate 2018-02-15 15:24:09 +03:00
luz.paz
e805a55a5b Misc. modules/ typos (cont.)
Found via `codespell`
2018-02-12 10:15:36 -05:00
Alexander Alekhin
d61528b2d5 Merge pull request #10833 from csukuangfj:improve-viz3d 2018-02-12 09:12:39 +00:00
Fangjun Kuang
2f3d4df2f2 improve the doc for the viz module. 2018-02-11 16:14:09 +08:00
Alexander Alekhin
44d7435a48 build: eliminate calls of removed functionality from C++17
Most part is deprecated since C++11
2018-02-07 12:00:33 +03:00
denmatfoton
b085158d59 Fix unstable work of stereoRectify function. Issue description: https://github.com/opencv/opencv/issues/10791 2018-02-05 15:30:26 -05:00
Alexander Alekhin
4a297a2443 ts: refactor OpenCV tests
- removed tr1 usage (dropped in C++17)
- moved includes of vector/map/iostream/limits into ts.hpp
- require opencv_test + anonymous namespace (added compile check)
- fixed norm() usage (must be from cvtest::norm for checks) and other conflict functions
- added missing license headers
2018-02-03 19:39:47 +00:00
Pavel Rojtberg
203dc3bb48 Merge pull request #10667 from paroj:stereo_calib_ex
calib3d: add stereoCalibrateExtended (#10667)

* cvCalibrateCamera2Internal: simplify per view error computation

* calib3d: add stereoCalibrateExtended

- allow CALIB_USE_EXTRINSIC_GUESS
- returns per view errors

* calib3d: add stereoCalibrateExtended test
2018-01-26 22:05:13 +03:00
Travers
7d6cf66303 IntrinsicParams operator+ fix 2018-01-26 14:04:45 +13:00
Fangjun Kuang
eb2901bd69 Improve the doc for fundamental matrix. 2018-01-19 13:41:47 +01:00
Fangjun Kuang
67842df9e2 Improve the documentation for affine transform estimation. 2018-01-18 19:54:18 +01:00
Alexander Alekhin
b067e0ca5d Merge pull request #10613 from csukuangfj:fix-10612 2018-01-17 09:58:34 +00:00
Alexander Alekhin
4a086cf517 Merge pull request #10609 from csukuangfj:patch-1 2018-01-17 09:02:50 +00:00
razerhell
fb22028be3 Merge pull request #10574 from razerhell:patch-1
* Newton's method can be more efficient

when we get the result of function distortPoint with a point (0, 0) and then undistortPoint with  the result, we get the point not (0, 0). and then we discovered that the old method is not convergence sometimes. finally we have gotten the right values by Newton's method.

* modify by advice  Newton's method...#10574

* calib3d(fisheye): fix codestyle, update theta before exit EPS check
2018-01-17 12:05:13 +03:00
csukuangfj
decf6cab5e Improve the documentation for cv::completeSymm and cv::RANSACUpdateNumIters. 2018-01-17 08:05:39 +01:00
Fangjun Kuang
2b635edce6 fix issue #10612. 2018-01-16 23:47:15 +01:00
Maksim Shabunin
8b87c4b96a Fixed several warnings produced by clang 6 and static analyzers 2018-01-16 15:26:28 +03:00
tobycollins
f34a0a874a Merge pull request #10522 from tobycollins:issue10519 2018-01-09 15:54:36 +03:00
catree
87160cb297 Add Demo 5: Basic panorama stitching from a rotating camera in the homography tutorial. 2017-12-19 22:45:35 +01:00
Suleyman TURKMEN
1654dfe3a9 Update samples (#10333)
* Update samples

* Update calib3d.hpp

* Update calib3d.hpp

* Update calib3d.hpp

* Update calib3d.hpp
2017-12-18 13:44:11 +03:00
catree
fcb537bacd Add a figure and some formulas to illustrate the PnP pose estimation principle. 2017-12-17 21:38:22 +01:00
Vitaly Tuzov
51cb56ef2c Implementation of bit-exact resize. Internal calls to linear resize updated to use bit-exact version. (#9468) 2017-12-13 15:00:38 +03:00
Maksim Shabunin
7349b8f5ce Build for embedded systems 2017-12-11 13:27:37 +03:00
Alexander Alekhin
74d321d901 Merge pull request #10199 from alalek:fix_calib3d_fisheye_rectify_test 2017-12-01 15:26:50 +00:00
Alexander Alekhin
ac58405a71 calib3d: fix fisheye stereoRectify test
- don't write into testdata directory
- check matrices instead of result images
2017-11-30 15:50:29 +03:00
Alexander Alekhin
9bf6ec6fe1 Revert "Adapted estimateNewCameraMatrix to make it work with pincushion-like distortion."
This reverts commit 5384a2205a.
2017-11-30 15:47:48 +03:00
Alexander Alekhin
e703c3090a Merge pull request #10184 from catree:solvePnP_iterative_guess_3_pts 2017-11-29 18:24:04 +00:00
catree
2e56a47f8c Allow to use 3 points in SolvePnP if SOLVEPNP_ITERATIVE and useExtrinsicGuess==true. Add bibtex citations for P3P. Update SolvPnP tests. 2017-11-28 15:04:59 +01:00
Alexander Alekhin
0ed3209b00 ocl: avoid unnecessary loading/initializing OpenCL subsystem
If there are no OpenCL/UMat methods calls from application.

OpenCL subsystem is initialized:
- haveOpenCL() is called from application
- useOpenCL() is called from application
- access to OpenCL allocator: UMat is created (empty UMat is ignored) or UMat <-> Mat conversions are called

Don't call OpenCL functions if OPENCV_OPENCL_RUNTIME=disabled
(independent from OpenCL linkage type)
2017-11-28 14:02:42 +03:00
Fakabbir Amin
a0c658b012 Merge pull request #9979 from fakabbir:ImproveDoc
* Improve Documentation
Fixes Spelling Mistakes.
2017-11-08 16:55:48 +00:00
Alexander Alekhin
6e4dacc0b3 Merge pull request #9971 from csukuangfj:fix-doc 2017-10-31 10:03:54 +00:00
KUANG Fangjun
67acfc6e25 improve doc. 2017-10-31 10:30:01 +01:00
Vadim Pisarevsky
87984f2c6a Merge pull request #9854 from opalmirror:test_stereo_min_disparity_master 2017-10-31 09:28:54 +00:00
James Perkins
4eb9f175a4 test_stereomatching.cpp: validate min disparity affect on valid ROI 2017-10-13 13:36:33 -07:00
Vladislav Vinogradov
26fe8bd4f2 made flann dependency for features2d optional
it will allow to build features2d even if flann module is not available
2017-10-13 14:59:39 +03:00
James Perkins
2cfe29276e fix StereoBM disparity map right margin truncation when minDisparities > 0 2017-10-09 14:51:36 -07:00
Alexander Alekhin
ab748188b1 Merge pull request #9596 from paroj:circle_board_params 2017-10-02 14:47:21 +00:00
Pavel Rojtberg
629a06d9b6 calib3d: export parameters of CALIB_CB_CLUSTERING 2017-10-02 14:27:32 +02:00
Alexander Alekhin
1f18282f04 build: fix MSVS2017 warning 2017-10-01 10:48:35 +00:00
Alexander Alekhin
99fae8146f Merge pull request #9626 from T0ny0:fisheye_fix_ 2017-09-15 20:29:39 +00:00
Tony0
2f0036c918 remove assignments in expressions 2017-09-15 22:45:17 +03:00
Tony0
62df5e8c8b fisheye: fix initUndistortRectifyMap() 2017-09-14 14:57:21 +03:00
Vladislav Sovrasov
b421ebef86 imgproc: slightly change the signature of undistortPoints overload 2017-09-14 12:19:40 +03:00
Vladislav Sovrasov
701c7e5685 imgproc: add stop criteria tuning in undistortPoints 2017-09-14 11:43:54 +03:00
Maksim Shabunin
248e2c7d47 Fixed some issues found by static analysis 2017-09-08 12:22:12 +03:00
Maksim Shabunin
2ac57a2b1f Merge pull request #9457 from alalek:type_traits_issue_7599 2017-09-06 13:34:29 +00:00
Suleyman TURKMEN
ee6aacee9c Update window_gtk.cpp
Update miniflann.cpp

Update test_stereomatching.cpp
2017-09-03 04:06:45 +03:00
Alexander Alekhin
7e12c879c2 core: extend traits::Type / traits::Depth for compatible types
DMatch and Keypoint are not compatible types (mixed float/int fields)
2017-08-31 19:35:48 +03:00
Vladislav Sovrasov
e0ff5106d3 calib3d: fix warning from gcc7 2017-08-25 16:29:59 +03:00
Vladislav Sovrasov
ef7833a271 calib3d: add CALIB_FIX_TANGENT_DIST flag to stereoCalibrate 2017-08-25 13:05:16 +03:00
Tomoaki Teshima
800f656402 suppress warning message 2017-08-14 08:26:06 +09:00
Alexander Alekhin
0e7edca7e3 Merge pull request #9340 from paroj:stereocalib_cpp 2017-08-10 10:24:29 +00:00
Pavel Rojtberg
5ada462773 calib3d: use cpp functions in cvStereoCalibrate to make it more readable 2017-08-09 17:21:14 +02:00
Alexander Alekhin
3786d30320 Merge pull request #9225 from paroj:reproject_cpp 2017-07-31 14:11:37 +00:00
Alexander Alekhin
2e17251160 calib3d: fix invalid memory access 2017-07-26 17:21:46 +03:00
Alexander Alekhin
bf0173bf38 ts: update valgrind suppressions 2017-07-26 17:21:45 +03:00
Pavel Rojtberg
94fdd45b75 calib3d: rewrite reprojectImageTo3D using Matx expressions
about the same speed, but significatly more readable
2017-07-24 17:36:31 +02:00
Tomoaki Teshima
e63d628677 remove some rand functions
* make test more reproducible
2017-07-20 22:43:11 +09:00
Alexander Alekhin
dcb3c4ff1e Merge pull request #9189 from tomoaki0705:fixCalib3dRandom 2017-07-20 12:24:34 +00:00
Tomoaki Teshima
46bee83005 fix the test fail on Calib3d_SolvePnP.accuracy
* move array size to enum
  * move array size to member variable
  * loosen the eps of SOLVEPNP_P3P
  * loosen the eps in Calib3d_SolveP3P.accuracy
2017-07-20 06:32:32 +09:00
Alexander Alekhin
42c0914382 Merge pull request #9086 from catree:improve_solvePnPRansac 2017-07-14 17:28:47 +00:00
Vladislav Sovrasov
fa17267e05 calib3d: fix not working CALIB_FIX_TANGENT_DIST flag 2017-07-13 10:49:35 +03:00
catree
98c78e0acd Use directly solvePnP when the number of input points is equal to the number of model points. Enable useExtrinsicGuess parameter. Return rvec and tvec estimated using all the inliers instead of the best rvec and tvec estimated during the Minimal Sample Sets step. Document the behavior of solvePnPRansac. 2017-07-05 13:17:38 +02:00
Alexander Alekhin
823353d3ac Merge pull request #9067 from D-Alex:master
Fix error message fisheye CALIB_CHECK_COND
2017-07-03 16:20:03 +00:00
Tony Lian
c8783f3e23 Merge pull request #9075 from TonyLianLong:master
Remove unnecessary Non-ASCII characters from source code (#9075)

* Remove unnecessary Non-ASCII characters from source code

Remove unnecessary Non-ASCII characters and replace them with ASCII
characters

* Remove dashes in the @param statement

Remove dashes and place single space in the @param statement to keep
coding style

* misc: more fixes for non-ASCII symbols

* misc: fix non-ASCII symbol in CMake file
2017-07-03 16:14:17 +00:00
Alexander Duda
5ca7dcc6e7 Fix error message fisheye CALIB_CHECK_COND
The old error message was not giving any hint which input array (image)
led to an ill conditioned matrix. This made it near impossible to
identify poor images in a larger set.

A better approach would be to implement a checker function which gives
each image a rating before the real calibration is performed. This could
also include some image properties like sharpness, etc.
2017-07-01 13:31:21 -02:30
Maksim Shabunin
1f23202ad8 Issues found by static analysis (5th round) 2017-07-01 18:56:24 +03:00
Maksim Shabunin
e0393f8557 Fixed some issues found by static analysis (4th round) 2017-06-30 12:26:53 +03:00
Alexander Alekhin
b84cbeec8c calib3d(perf): disable SGBM tests in debug mode
because they are too long (takes minutes)
2017-06-29 12:49:47 +03:00
Alexander Alekhin
324851882a Merge pull request #9025 from mshabunin:fix-static-3 2017-06-28 20:50:21 +00:00
Maksim Shabunin
a769d69a9d Fixed several issues found by static analysis 2017-06-28 18:06:18 +03:00
Tong Ke
8088d6785a Merge pull request #8585 from tonyke1993:ap3p
Enable p3p and ap3p in solvePnPRansac (#8585)

* add paper info

* allow p3p and ap3p being RANSAC kernel

* keep previous code

* apply catrees comment

* fix getMat

* add comment

* add solvep3p test

* test return value

* fix warnings
2017-06-28 15:27:30 +03:00
Maksim Shabunin
32d4af36e2 Fixing some static analysis issues 2017-06-27 14:30:26 +03:00
Alexander Alekhin
006966e629 trace: initial support for code trace 2017-06-26 17:07:13 +03:00
Alexander Alekhin
43b03b6517 Merge pull request #8864 from sovrasov:calib_flags_update 2017-06-20 15:12:50 +00:00
abratchik
037d8fbdcd Refactor OpenCV Java Wrapping 2017-06-15 20:35:12 +04:00
Vladislav Sovrasov
c0e456dee2 calib3d: use calibration flags from the new enums 2017-06-13 19:55:53 +03:00
Vladislav Sovrasov
d121d1c528 calib3d: add CALIB_FIX_TANGENT_DIST flag 2017-06-13 19:40:49 +03:00
Vadim Pisarevsky
31c79668c8 Merge pull request #8803 from 4ekmah:sgbm_modehh4_SIMD 2017-06-07 13:35:53 +00:00
Pyotr Chekmaryov
a113e8f088 Fixing buildbot's messages. 2017-06-04 20:32:07 +03:00
Maksim Shabunin
9bb17caa24 Merge pull request #8842 from delftrobotics-forks:compile_fix_circlesgrid_debug 2017-06-02 10:19:33 +00:00
rmensing
79bb920dee Compile fix for circlesgrid in debug. 2017-06-01 16:00:13 +02:00
catree
542cdb2c39 Improve solvePnP doc, add assert >= 4 in solvePnP, escape underscore character for Scalar_ documentation.
Add reference to SOLVEPNP_ITERATIVE in the doc.
2017-05-29 14:59:14 +02:00
Pyotr Chekmaryov
c26fd68236 Performance tests are added. 2017-05-26 22:48:03 +00:00
Vladislav Sovrasov
bf8415283a calib3d: replace defines with enum values 2017-05-24 15:50:41 +03:00
Pyotr Chekmaryov
ba39bb8da8 SIMD for modeHH4 is added. Plus some small optimization of CalcBT func. 2017-05-17 22:11:02 +00:00
Vadim Pisarevsky
dea5eaca30 Merge pull request #8660 from 4ekmah:making_sgbm_parallel 2017-05-03 13:47:36 +00:00
jveitchmichaelis
369bfbfd23 Add default parameters for SGBM::create
Added default parameters for minDisparity, numDisparities and blockSize. This fixes a bug where SGBM::load would not compile.
2017-04-30 16:32:30 +01:00
Pyotr Chekmaryov
d6bc6895a6 Test data correction. 2017-04-27 10:05:55 +00:00
Pyotr Chekmaryov
21be2aa677 Memory repaired + Cleanup. 2017-04-25 21:00:31 +00:00
Pyotr Chekmaryov
7ffa49e02c Vertical passes added and we have working parralel version. 2017-04-22 00:00:08 +00:00
Alexander Alekhin
b4f22803cd Merge pull request #8593 from devnexen:test_fixes 2017-04-21 12:41:10 +00:00
Alexander Alekhin
f1c8094f5f Merge pull request #8575 from lupustr3:pvlasov/icv2017u2_initial_update 2017-04-21 10:55:29 +00:00
Pavel Vlasov
35c7216846 IPP for OpenCV 2017u2 initial enabling patch; 2017-04-20 20:26:30 +03:00
David Carlier
bacc210606 fixing segfaults occuring when launching those unit tests 2017-04-18 09:50:17 +01:00
Tomoaki Teshima
62c17dc3cf fix typo and align white spaces 2017-04-17 08:32:08 +09:00
Pyotr Chekmaryov
20036b82d3 There added parallel realization of vertical passes for MODE_HH4. 2017-04-15 21:51:15 +00:00
Tomoaki Teshima
c145f28c71 fix build error on VS2012 2017-04-12 20:09:00 +09:00
Alexander Alekhin
a2af1d4f71 Merge pull request #8458 from grundman:patch-2 2017-04-11 10:06:34 +00:00
Tong Ke
0a63ab36bb Merge pull request #8301 from tonyke1993:p3p_alg
New p3p algorithm (accepted by CVPR 2017) (#8301)

* add p3p source code

* indent 4

* update publication info

* fix filename

* interface done

* plug in done, test needed

* debugging

* for test

* a working version

* clean p3p code

* test

* test

* fix warning, blank line

* apply patch from @catree

* add reference info

* namespace, indent 4

* static solveQuartic

* put small functions to anonymous namespace
2017-04-07 09:48:34 +03:00
Paolo Perkovic
dd576c89a3 Fix StereoBM ROI selection
- Fix StereoBM ROI (Region of interest) selection for stereo
images used by block matching algorithm
2017-04-01 13:29:44 +02:00
Matthias Grundmann
de52887c49 Update circlesgrid.cpp
Use identity matrix if homography finding failed. Current behavior zeros out all points.

Update circlesgrid.cpp

Addressed comments

Update circlesgrid.cpp

removed whitespace
2017-03-28 10:56:12 +03:00
Pyotr Chekmaryov
106413a3ea Simplest test added and code debuged. 2017-03-27 21:40:17 +00:00
q
2918c3d75a First occurence of 4-directional version of SGBM.
Even without any tests.
Next step is parallelising it.
2017-03-21 14:51:19 +00:00
Maksim Shabunin
a83a1cafa7 Merge pull request #8388 from ottogin:calib3d 2017-03-15 04:33:33 +00:00
Artem Lukoyanov
3bf5d34544 Callib3d 4channel image detection
3.2 version doesn't support 4 channel color image
detections, unlike 3.1. Now, we don't call
CV_Error() if 4 channel image is given.

resolve #8326
2017-03-15 02:54:15 +03:00
Alexander Alekhin
aa5204958e Merge pull request #8279 from sovrasov:calib3d_new_recover_pose 2017-03-06 10:20:43 +00:00
Hans Gaiser
11b24eb49f Expose CirclesGridFinderParameters in findCirclesGrid. 2017-03-02 10:53:45 +01:00
Vladislav Sovrasov
710506e9e2 calib3d: add a new overload for recoverPose 2017-02-27 13:26:04 +03:00
Vadim Pisarevsky
12d7429ff0 Merge pull request #8064 from terfendail:sgbm_bigbuffer 2017-02-23 20:11:26 +00:00
Vitaly Tuzov
4950f542d1 Fix for SGBM compute() buffer allocation failure on big images 2017-02-08 12:49:21 +03:00
Alexander Alekhin
124c4825a7 Merge pull request #8089 from hrnr:estimate_convert_fix
fix wrong conversion in estimateAffine2D* functions
2017-01-30 16:53:50 +03:00
Jiri Horner
4ee25c7e95 add test for convertions in estimateAffine2D* functions
test with integer points to cover conversion bugs.
2017-01-27 22:16:58 +01:00
Jiri Horner
9408a5ef5d fix conversion bug in estimateAffine2D* functions
functions support points to have other datatypes than floats.

* fix bug in coversion that overwrites src points with dst points
2017-01-27 16:55:29 +01:00
Alexander Alekhin
c1dec72fb6 java: force 64F in solvePnP test 2017-01-25 19:42:09 +03:00
Alexander Alekhin
3413c23b34 Merge pull request #8061 from tomoaki0705:universalIntrinsicStereoCalib3d 2017-01-25 16:08:02 +00:00
Pavel Rojtberg
3e708e015c solvePnP: use CV_32F for rvec, tvec if all PnP inputs are CV_32F 2017-01-24 18:17:46 +01:00
Tomoaki Teshima
b34ebc8cfe use universal intrinsic in stereo matching
- check SIMD availability before executing
2017-01-24 18:25:22 +09:00
Vadim Pisarevsky
c0cde75d54 Merge pull request #7975 from tomoaki0705:cleanupCalib3dStereo 2017-01-10 11:12:15 +00:00