Skip to content

Commit

Permalink
Rename functions: CreateLerp() => Lerp()
Browse files Browse the repository at this point in the history
  • Loading branch information
mogemimi committed Dec 24, 2015
1 parent 1ba5c18 commit e0f19a4
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 22 deletions.
16 changes: 8 additions & 8 deletions include/Pomdog/Math/detail/FloatingPointMatrix3x2.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,14 @@ class POMDOG_EXPORT FloatingPointMatrix3x2 {
static FloatingPointMatrix3x2
Invert(FloatingPointMatrix3x2 const& matrix);

static void
Lerp(FloatingPointMatrix3x2 const& source1, FloatingPointMatrix3x2 const& source2,
T amount, FloatingPointMatrix3x2 & result) noexcept;

static FloatingPointMatrix3x2
Lerp(FloatingPointMatrix3x2 const& source1, FloatingPointMatrix3x2 const& source2,
T amount) noexcept;

static void
CreateTranslation(FloatingPointVector2<T> const& position, FloatingPointMatrix3x2 & result) noexcept;

Expand Down Expand Up @@ -102,14 +110,6 @@ class POMDOG_EXPORT FloatingPointMatrix3x2 {
static FloatingPointMatrix3x2
CreateSkew(FloatingPointVector2<T> const& skew);

static void
CreateLerp(FloatingPointMatrix3x2 const& source1, FloatingPointMatrix3x2 const& source2,
T amount, FloatingPointMatrix3x2 & result) noexcept;

static FloatingPointMatrix3x2
CreateLerp(FloatingPointMatrix3x2 const& source1, FloatingPointMatrix3x2 const& source2,
T amount) noexcept;

///@brief Returns pointer to the first element.
T const* Data() const noexcept;

Expand Down
16 changes: 8 additions & 8 deletions include/Pomdog/Math/detail/FloatingPointMatrix3x3.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,14 @@ class POMDOG_EXPORT FloatingPointMatrix3x3 {
static FloatingPointMatrix3x3
Invert(FloatingPointMatrix3x3 const& matrix);

static void
Lerp(FloatingPointMatrix3x3 const& source1, FloatingPointMatrix3x3 const& source2,
T amount, FloatingPointMatrix3x3 & result) noexcept;

static FloatingPointMatrix3x3
Lerp(FloatingPointMatrix3x3 const& source1, FloatingPointMatrix3x3 const& source2,
T amount) noexcept;

static void
CreateTranslation(FloatingPointVector2<T> const& position, FloatingPointMatrix3x3 & result) noexcept;

Expand Down Expand Up @@ -129,14 +137,6 @@ class POMDOG_EXPORT FloatingPointMatrix3x3 {
static FloatingPointMatrix3x3
CreateFromQuaternion(FloatingPointQuaternion<T> const& quaternion);

static void
CreateLerp(FloatingPointMatrix3x3 const& source1, FloatingPointMatrix3x3 const& source2,
T amount, FloatingPointMatrix3x3 & result) noexcept;

static FloatingPointMatrix3x3
CreateLerp(FloatingPointMatrix3x3 const& source1, FloatingPointMatrix3x3 const& source2,
T amount) noexcept;

static void
CreateFromAxisAngle(FloatingPointVector3<T> const& axis, Radian<T> const& angle, FloatingPointMatrix3x3 & result);

Expand Down
6 changes: 3 additions & 3 deletions src/Math/detail/FloatingPointMatrix3x2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ FloatingPointMatrix3x2<T>::CreateSkew(FloatingPointVector2<T> const& skew)
//-----------------------------------------------------------------------
template <typename T>
void
FloatingPointMatrix3x2<T>::CreateLerp(FloatingPointMatrix3x2 const& source1,
FloatingPointMatrix3x2<T>::Lerp(FloatingPointMatrix3x2 const& source1,
FloatingPointMatrix3x2 const& source2, T amount, FloatingPointMatrix3x2 & result) noexcept
{
result.m[0][0] = source1.m[0][0] + ((source2.m[0][0] - source1.m[0][0]) * amount);
Expand All @@ -369,11 +369,11 @@ FloatingPointMatrix3x2<T>::CreateLerp(FloatingPointMatrix3x2 const& source1,
//-----------------------------------------------------------------------
template <typename T>
FloatingPointMatrix3x2<T>
FloatingPointMatrix3x2<T>::CreateLerp(FloatingPointMatrix3x2 const& source1,
FloatingPointMatrix3x2<T>::Lerp(FloatingPointMatrix3x2 const& source1,
FloatingPointMatrix3x2 const& source2, T amount) noexcept
{
FloatingPointMatrix3x2 result;
CreateLerp(source1, source2, amount, result);
Lerp(source1, source2, amount, result);
return std::move(result);
}
//-----------------------------------------------------------------------
Expand Down
6 changes: 3 additions & 3 deletions src/Math/detail/FloatingPointMatrix3x3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,7 @@ FloatingPointMatrix3x3<T>::CreateFromQuaternion(FloatingPointQuaternion<T> const
//-----------------------------------------------------------------------
template <typename T>
void
FloatingPointMatrix3x3<T>::CreateLerp(FloatingPointMatrix3x3 const& source1,
FloatingPointMatrix3x3<T>::Lerp(FloatingPointMatrix3x3 const& source1,
FloatingPointMatrix3x3 const& source2, T amount, FloatingPointMatrix3x3 & result) noexcept
{
result.m[0][0] = source1.m[0][0] + ((source2.m[0][0] - source1.m[0][0]) * amount);
Expand All @@ -576,11 +576,11 @@ FloatingPointMatrix3x3<T>::CreateLerp(FloatingPointMatrix3x3 const& source1,
//-----------------------------------------------------------------------
template <typename T>
FloatingPointMatrix3x3<T>
FloatingPointMatrix3x3<T>::CreateLerp(FloatingPointMatrix3x3 const& source1,
FloatingPointMatrix3x3<T>::Lerp(FloatingPointMatrix3x3 const& source1,
FloatingPointMatrix3x3 const& source2, T amount) noexcept
{
FloatingPointMatrix3x3 result;
CreateLerp(source1, source2, amount, result);
Lerp(source1, source2, amount, result);
return std::move(result);
}
//-----------------------------------------------------------------------
Expand Down

0 comments on commit e0f19a4

Please sign in to comment.