diff options
author | wwylele <wwylele@gmail.com> | 2017-07-11 18:51:29 +0200 |
---|---|---|
committer | wwylele <wwylele@gmail.com> | 2017-07-11 18:51:29 +0200 |
commit | f3660ba9dd13f342c591aaa9901e94b6caee8d9a (patch) | |
tree | 9332c3fa8ad03a7e03d384c1403100734d7a4f61 | |
parent | SwRasterizer/Lighting: Move the clamp highlight calculation to the end of the per-light loop body. (diff) | |
download | yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.tar yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.tar.gz yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.tar.bz2 yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.tar.lz yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.tar.xz yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.tar.zst yuzu-f3660ba9dd13f342c591aaa9901e94b6caee8d9a.zip |
-rw-r--r-- | src/common/vector_math.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/common/vector_math.h b/src/common/vector_math.h index d0fe0e405..49ae87f6d 100644 --- a/src/common/vector_math.h +++ b/src/common/vector_math.h @@ -31,7 +31,6 @@ #pragma once #include <cmath> -#include <type_traits> namespace Math { @@ -90,7 +89,7 @@ public: x -= other.x; y -= other.y; } - template <typename Q = T, class = typename std::enable_if<std::is_signed<Q>::value>::type> + Vec2<decltype(-T{})> operator-() const { return MakeVec(-x, -y); } @@ -247,7 +246,7 @@ public: y -= other.y; z -= other.z; } - template <typename Q = T, class = typename std::enable_if<std::is_signed<Q>::value>::type> + Vec3<decltype(-T{})> operator-() const { return MakeVec(-x, -y, -z); } |