Multiple fixes for WinRT
Fixed flann build with NEON; Fixed Haming distance with NEON; Honest cvRound for WinRT added; cvRound test added; Video IO with direct show disabled;
This commit is contained in:
@@ -136,7 +136,6 @@ CV_INLINE IppiSize ippiSize(int width, int height)
|
||||
#ifdef __ARM_NEON__
|
||||
# include <arm_neon.h>
|
||||
# define CV_NEON 1
|
||||
# define CPU_HAS_NEON_FEATURE (true)
|
||||
#endif
|
||||
|
||||
#ifndef CV_SSE
|
||||
|
@@ -323,7 +323,12 @@ CV_INLINE int cvRound( double value )
|
||||
# endif
|
||||
#else
|
||||
// while this is not IEEE754-compliant rounding, it's usually a good enough approximation
|
||||
return (int)(value + (value >= 0 ? 0.5 : -0.5));
|
||||
double intpart, fractpart;
|
||||
fractpart = modf(value, &intpart);
|
||||
if ((abs(fractpart) != 0.5) || ((((int)intpart) % 2) != 0))
|
||||
return (int)(value + (value >= 0 ? 0.5 : -0.5));
|
||||
else
|
||||
return (int)intpart;
|
||||
#endif
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user