mirror of
https://github.com/opencv/opencv.git
synced 2025-06-10 19:24:07 +08:00
Fix iOS warnings about implicit conversion precision by changing double literals to float ones
Conflicts: modules/contrib/include/opencv2/contrib/retina.hpp
This commit is contained in:
parent
655b28ee0c
commit
63dbeeaac5
@ -253,7 +253,7 @@ void cv::Affine3<T>::rotation(const Vec3& _rvec)
|
|||||||
double c = std::cos(theta);
|
double c = std::cos(theta);
|
||||||
double s = std::sin(theta);
|
double s = std::sin(theta);
|
||||||
double c1 = 1. - c;
|
double c1 = 1. - c;
|
||||||
double itheta = theta ? 1./theta : 0.;
|
double itheta = (theta != 0) ? 1./theta : 0.;
|
||||||
|
|
||||||
rx *= itheta; ry *= itheta; rz *= itheta;
|
rx *= itheta; ry *= itheta; rz *= itheta;
|
||||||
|
|
||||||
|
@ -89,13 +89,13 @@ struct CV_EXPORTS LinearIndexParams : public IndexParams
|
|||||||
struct CV_EXPORTS CompositeIndexParams : public IndexParams
|
struct CV_EXPORTS CompositeIndexParams : public IndexParams
|
||||||
{
|
{
|
||||||
CompositeIndexParams(int trees = 4, int branching = 32, int iterations = 11,
|
CompositeIndexParams(int trees = 4, int branching = 32, int iterations = 11,
|
||||||
cvflann::flann_centers_init_t centers_init = cvflann::FLANN_CENTERS_RANDOM, float cb_index = 0.2 );
|
cvflann::flann_centers_init_t centers_init = cvflann::FLANN_CENTERS_RANDOM, float cb_index = 0.2f );
|
||||||
};
|
};
|
||||||
|
|
||||||
struct CV_EXPORTS AutotunedIndexParams : public IndexParams
|
struct CV_EXPORTS AutotunedIndexParams : public IndexParams
|
||||||
{
|
{
|
||||||
AutotunedIndexParams(float target_precision = 0.8, float build_weight = 0.01,
|
AutotunedIndexParams(float target_precision = 0.8f, float build_weight = 0.01f,
|
||||||
float memory_weight = 0, float sample_fraction = 0.1);
|
float memory_weight = 0, float sample_fraction = 0.1f);
|
||||||
};
|
};
|
||||||
|
|
||||||
struct CV_EXPORTS HierarchicalClusteringIndexParams : public IndexParams
|
struct CV_EXPORTS HierarchicalClusteringIndexParams : public IndexParams
|
||||||
@ -107,7 +107,7 @@ struct CV_EXPORTS HierarchicalClusteringIndexParams : public IndexParams
|
|||||||
struct CV_EXPORTS KMeansIndexParams : public IndexParams
|
struct CV_EXPORTS KMeansIndexParams : public IndexParams
|
||||||
{
|
{
|
||||||
KMeansIndexParams(int branching = 32, int iterations = 11,
|
KMeansIndexParams(int branching = 32, int iterations = 11,
|
||||||
cvflann::flann_centers_init_t centers_init = cvflann::FLANN_CENTERS_RANDOM, float cb_index = 0.2 );
|
cvflann::flann_centers_init_t centers_init = cvflann::FLANN_CENTERS_RANDOM, float cb_index = 0.2f );
|
||||||
};
|
};
|
||||||
|
|
||||||
struct CV_EXPORTS LshIndexParams : public IndexParams
|
struct CV_EXPORTS LshIndexParams : public IndexParams
|
||||||
|
Loading…
Reference in New Issue
Block a user