瀏覽代碼

Expanded traits from DsrTrait_Scalar to DsrTrait_Any, to allow calling min and max with more than two SIMD vectors in the same function call.

David Piuva 5 月之前
父節點
當前提交
8151a5c91f
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      Source/DFPSR/base/noSimd.h

+ 2 - 2
Source/DFPSR/base/noSimd.h

@@ -114,7 +114,7 @@ namespace dsr {
 	inline T min(const T &a, const T &b) {
 		return (a < b) ? a : b;
 	}
-	template <typename T, typename... TAIL, DSR_ENABLE_IF(DSR_CHECK_PROPERTY(DsrTrait_Scalar, T))>
+	template <typename T, typename... TAIL, DSR_ENABLE_IF(DSR_CHECK_PROPERTY(DsrTrait_Any, T))>
 	inline T min(const T &a, const T &b, TAIL... tail) {
 		return min(min(a, b), tail...);
 	}
@@ -125,7 +125,7 @@ namespace dsr {
 	inline T max(const T &a, const T &b) {
 		return (a > b) ? a : b;
 	}
-	template <typename T, typename... TAIL, DSR_ENABLE_IF(DSR_CHECK_PROPERTY(DsrTrait_Scalar, T))>
+	template <typename T, typename... TAIL, DSR_ENABLE_IF(DSR_CHECK_PROPERTY(DsrTrait_Any, T))>
 	inline T max(const T &a, const T &b, TAIL... tail) {
 		return max(max(a, b), tail...);
 	}