Use proper C++ types again.

This is necessary to get https://github.com/opencv/opencv/pull/25248 working.
This was missed in 5300337197
pull/3705/head
Vincent Rabaud 1 year ago
parent c8c750a98b
commit 9edb0cee37
  1. 6
      modules/xphoto/src/norm2.hpp

@ -59,10 +59,10 @@ template <class T> struct same_as<T, T> : ttype {}; // is_same
template <typename _Tp> struct is_norm2_type : template <typename _Tp> struct is_norm2_type :
int_const<bool, !same_as<_Tp, char>::value int_const<bool, !same_as<_Tp, int8_t>::value
&& !same_as<_Tp, uint8_t>::value && !same_as<_Tp, uint8_t>::value
&& !same_as<_Tp, ushort>::value && !same_as<_Tp, uint16_t>::value
&& !same_as<_Tp, uint>::value>{}; && !same_as<_Tp, uint32_t>::value>{};
template <typename _Tp, int cn> static inline typename iftype< is_norm2_type<_Tp>::value, _Tp >:: template <typename _Tp, int cn> static inline typename iftype< is_norm2_type<_Tp>::value, _Tp >::
type norm2(cv::Vec<_Tp, cn> a, cv::Vec<_Tp, cn> b) { return (a - b).dot(a - b); } type norm2(cv::Vec<_Tp, cn> a, cv::Vec<_Tp, cn> b) { return (a - b).dot(a - b); }

Loading…
Cancel
Save