mirror of
https://github.com/opencv/opencv.git
synced 2024-11-29 05:29:54 +08:00
fixed include for Windows
This commit is contained in:
parent
406f342dc3
commit
2a48f7c035
@ -41,9 +41,15 @@
|
|||||||
//M*/
|
//M*/
|
||||||
|
|
||||||
#include "precomp.hpp"
|
#include "precomp.hpp"
|
||||||
#include <math.h>
|
|
||||||
#include "opencv2/calib3d/calib3d_c.h"
|
#include "opencv2/calib3d/calib3d_c.h"
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
#include <float.h>
|
||||||
|
#define isnan(x) _isnan(x)
|
||||||
|
#else
|
||||||
|
#include <math.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
using namespace cv;
|
using namespace cv;
|
||||||
using namespace cv::detail;
|
using namespace cv::detail;
|
||||||
|
|
||||||
@ -253,8 +259,7 @@ bool BundleAdjusterBase::estimate(const std::vector<ImageFeatures> &features,
|
|||||||
bool ok = true;
|
bool ok = true;
|
||||||
for (int i = 0; i < cam_params_.rows; ++i)
|
for (int i = 0; i < cam_params_.rows; ++i)
|
||||||
{
|
{
|
||||||
if (isnan(cam_params_.at<double>(i,0)) ||
|
if (isnan(cam_params_.at<double>(i,0)))
|
||||||
isinf(cam_params_.at<double>(i,0)))
|
|
||||||
{
|
{
|
||||||
ok = false;
|
ok = false;
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user