Skip to content

Add check for CALIB_USE_EXTRINSIC_GUESS in stereoCalibrate - #12731

Merged
alalek merged 2 commits into
opencv:3.4from
UnderscoreAsterisk:fix-12012
Oct 3, 2018
Merged

alalek merged 2 commits into
opencv:3.4from
UnderscoreAsterisk:fix-12012

Conversation

@UnderscoreAsterisk

@UnderscoreAsterisk UnderscoreAsterisk commented Oct 3, 2018 •

Copy link
Copy Markdown
Contributor

resolves #12012
related #12334

I've added a check for CALIB_USE_EXTRINSIC_GUESS such that an error is raised if this flag is set in stereoCalibrate. This commit is created to fix issue #12012.

Comment thread modules/calib3d/src/calibration.cpp Outdated
TermCriteria criteria)
{
if (flags & CALIB_USE_EXTRINSIC_GUESS)
CV_Error(CV_StsBadFlag, "stereoCalibrate does not support CALIB_USE_EXTRINSIC_GUESS.");

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CV_StsBadFlag

Please use values from cv::Error enum: Error::StsBadFlag.

@alalek

alalek commented Oct 3, 2018

Copy link
Copy Markdown
Member

Looks good to me.

As a bugfix this patch should go into 3.4 branch. We will merge changes from 3.4 into master regularly (weekly/bi-weekly).

So, please:

  • change "base" branch of this PR: master => 3.4 (use "Edit" button near PR title)
  • rebase your commits from master onto 3.4 branch. For example:
    git rebase -i --onto upstream/3.4 upstream/master
    (check list of your commits, save and quit (Esc + "wq" + Enter)
    where upstream is configured by following this GitHub guide and fetched (git fetch upstream).
  • push rebased commits into source branch of your fork (with --force option)

Note: no needs to re-open PR, apply changes "inplace".

@UnderscoreAsterisk
UnderscoreAsterisk changed the base branch from master to 3.4 October 3, 2018 09:08

@alalek alalek left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well done! Thank you 👍

@alalek
alalek merged commit 0ffc186 into opencv:3.4 Oct 3, 2018
@alalek alalek mentioned this pull request Oct 9, 2018
@UnderscoreAsterisk
UnderscoreAsterisk deleted the fix-12012 branch October 11, 2018 04:40
SavyaSanchi-Sharma pushed a commit to SavyaSanchi-Sharma/opencv that referenced this pull request Jul 30, 2026
* fix opencv#12012

* Replace CV_StsBadFlag with Error::StsBadFlag
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants