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