Math/VectorI: Add Apply static method
This commit is contained in:
committed by
Jérôme Leclercq
parent
addbb98671
commit
c826b537ab
@@ -644,6 +644,12 @@ namespace Nz
|
||||
return w >= vec.w;
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
constexpr Vector4<T> Vector4<T>::Apply(T(*func)(T), const Vector4& vec)
|
||||
{
|
||||
return Vector4(func(vec.x), func(vec.y), func(vec.z), func(vec.w));
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
constexpr bool Vector4<T>::ApproxEqual(const Vector4& lhs, const Vector4& rhs, T maxDifference)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user