Skip to content

Commit

Permalink
Syntax fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dgirardeau committed Jun 30, 2024
1 parent 1aa501a commit 1a4fb18
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions include/CCGeom.h
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ template <typename Type> class Vector2Tpl
//! Returns vector norm (forces double precision output)
inline double normd() const { return std::sqrt(norm2d()); }
//! Sets vector norm to unity
inline void normalize() { double n = normd(); if (n >= std::numeric_limits<double>::epsilon()) *this /= static_cast<Type>(n); }
inline void normalize() { Type n = norm(); if (n >= std::numeric_limits<Type>::epsilon()) *this /= n; }

//! Dot product
inline Type dot(const Vector2Tpl& v) const { return (x*v.x) + (y*v.y); }
Expand Down Expand Up @@ -201,7 +201,7 @@ template <typename Type> class Vector3Tpl : public Tuple3Tpl<Type>
//! Returns vector norm (forces double precision output)
inline double normd() const { return std::sqrt(norm2d()); }
//! Sets vector norm to unity
inline void normalize() { double n = normd(); if (n >= std::numeric_limits<double>::epsilon()) *this /= static_cast<Type>(n); }
inline void normalize() { Type n = norm(); if (n >= std::numeric_limits<Type>::epsilon()) *this /= n; }
//! Returns a normalized vector which is orthogonal to this one
inline Vector3Tpl orthogonal() const { Vector3Tpl ort; vorthogonal(u, ort.u); return ort; }

Expand Down
4 changes: 2 additions & 2 deletions include/SquareMatrix.h
Original file line number Diff line number Diff line change
Expand Up @@ -127,13 +127,13 @@ namespace CCCoreLib
inline Scalar* row(unsigned index) { return m_values[index]; }

//! Sets a particular matrix value
void inline setValue(unsigned row, unsigned column, Scalar value)
inline void setValue(unsigned row, unsigned column, Scalar value)
{
m_values[row][column] = value;
}

//! Returns a specific matrix value
Scalar inline getValue(unsigned row, unsigned column) const
inline Scalar getValue(unsigned row, unsigned column) const
{
return m_values[row][column];
}
Expand Down

0 comments on commit 1a4fb18

Please sign in to comment.