Indentations
Former-commit-id: 0d82a4464cb9369bc4ca5cf2d7780c921eff953d
This commit is contained in:
@@ -80,7 +80,6 @@ class NzMatrix4
|
||||
NzMatrix4& Set(const T matrix[16]);
|
||||
//NzMatrix4(const NzMatrix3<T>& matrix);
|
||||
NzMatrix4& Set(const NzMatrix4& matrix);
|
||||
NzMatrix4& Set(NzMatrix4&& matrix);
|
||||
template<typename U> NzMatrix4& Set(const NzMatrix4<U>& matrix);
|
||||
NzMatrix4& SetRotation(const NzQuaternion<T>& rotation);
|
||||
NzMatrix4& SetScale(const NzVector3<T>& scale);
|
||||
|
||||
@@ -28,14 +28,12 @@ class NzVector3
|
||||
~NzVector3() = default;
|
||||
|
||||
T AbsDotProduct(const NzVector3& vec) const;
|
||||
|
||||
T AngleBetween(const NzVector3& vec) const;
|
||||
|
||||
NzVector3 CrossProduct(const NzVector3& vec) const;
|
||||
|
||||
T Distance(const NzVector3& vec) const;
|
||||
float Distancef(const NzVector3& vec) const;
|
||||
|
||||
T DotProduct(const NzVector3& vec) const;
|
||||
|
||||
T GetLength() const;
|
||||
|
||||
@@ -64,9 +64,9 @@ template<typename T>
|
||||
T NzVector3<T>::AngleBetween(const NzVector3& vec) const
|
||||
{
|
||||
// sqrt(a) * sqrt(b) = sqrt(a*b)
|
||||
T divisor = std::sqrt(GetSquaredLength() * vec.GetSquaredLength());
|
||||
T divisor = std::sqrt(GetSquaredLength() * vec.GetSquaredLength());
|
||||
|
||||
#if NAZARA_MATH_SAFE
|
||||
#if NAZARA_MATH_SAFE
|
||||
if (NzNumberEquals(divisor, F(0.0)))
|
||||
{
|
||||
NzString error("Division by zero");
|
||||
@@ -325,7 +325,7 @@ NzVector3<T>& NzVector3<T>::Set(const NzVector4<T>& vec)
|
||||
template<typename T>
|
||||
T NzVector3<T>::SquaredDistance(const NzVector3& vec) const
|
||||
{
|
||||
return operator-(vec).GetSquaredLength();
|
||||
return (*this - vec).GetSquaredLength();
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
|
||||
@@ -121,11 +121,11 @@ NzVector4<T>& NzVector4<T>::Maximize(const NzVector4& vec)
|
||||
if (vec.y > y)
|
||||
y = vec.y;
|
||||
|
||||
if (vec.z > z)
|
||||
z = vec.z;
|
||||
if (vec.z > z)
|
||||
z = vec.z;
|
||||
|
||||
if (vec.w > w)
|
||||
w = vec.w;
|
||||
if (vec.w > w)
|
||||
w = vec.w;
|
||||
|
||||
return *this;
|
||||
}
|
||||
@@ -139,11 +139,11 @@ NzVector4<T>& NzVector4<T>::Minimize(const NzVector4& vec)
|
||||
if (vec.y < y)
|
||||
y = vec.y;
|
||||
|
||||
if (vec.z < z)
|
||||
z = vec.z;
|
||||
if (vec.z < z)
|
||||
z = vec.z;
|
||||
|
||||
if (vec.w < w)
|
||||
w = vec.w;
|
||||
if (vec.w < w)
|
||||
w = vec.w;
|
||||
|
||||
return *this;
|
||||
}
|
||||
@@ -447,9 +447,9 @@ template<typename T>
|
||||
bool NzVector4<T>::operator==(const NzVector4& vec) const
|
||||
{
|
||||
return NzNumberEquals(x, vec.x) &&
|
||||
NzNumberEquals(y, vec.y) &&
|
||||
NzNumberEquals(z, vec.z) &&
|
||||
NzNumberEquals(w, vec.w);
|
||||
NzNumberEquals(y, vec.y) &&
|
||||
NzNumberEquals(z, vec.z) &&
|
||||
NzNumberEquals(w, vec.w);
|
||||
}
|
||||
|
||||
template<typename T>
|
||||
|
||||
Reference in New Issue
Block a user