1
0
mirror of https://github.com/opencv/opencv.git synced 2026-07-30 07:43:03 +04:00

fix abs_func and minimum/maximum functors

This commit is contained in:
Vladislav Vinogradov
2012-11-12 12:18:31 +04:00
parent afff9cf716
commit d47c112434
4 changed files with 86 additions and 15 deletions
+2 -2
View File
@@ -267,7 +267,7 @@ namespace cv { namespace gpu { namespace device
}
__device__ __forceinline__ float4 abs_(const float4& a)
{
return fabs(a);
return abs(a);
}
template <int cn, int PATCH_X, int PATCH_Y, bool calcErr>
@@ -681,4 +681,4 @@ namespace cv { namespace gpu { namespace device
}
}}}
#endif /* CUDA_DISABLER */
#endif /* CUDA_DISABLER */
+2 -2
View File
@@ -638,7 +638,7 @@ namespace cv { namespace gpu { namespace device
kp_dir *= 180.0f / CV_PI_F;
kp_dir = 360.0f - kp_dir;
if (abs(kp_dir - 360.f) < FLT_EPSILON)
if (::fabsf(kp_dir - 360.f) < FLT_EPSILON)
kp_dir = 0.f;
featureDir[blockIdx.x] = kp_dir;
@@ -1003,4 +1003,4 @@ namespace cv { namespace gpu { namespace device
}}} // namespace cv { namespace gpu { namespace device
#endif /* CUDA_DISABLER */
#endif /* CUDA_DISABLER */