mirror of
https://github.com/HandmadeMath/HandmadeMath.git
synced 2026-01-01 01:12:01 +00:00
Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5d1393e874 |
3000
HandmadeMath.h
3000
HandmadeMath.h
File diff suppressed because it is too large
Load Diff
@@ -10,8 +10,6 @@ To get started, go download [the latest release](https://github.com/HandmadeMath
|
|||||||
|
|
||||||
Version | Changes |
|
Version | Changes |
|
||||||
----------------|----------------|
|
----------------|----------------|
|
||||||
|
|
||||||
**1.13.0** | Inline all Handmade Math functions. Remove need for HANDMADE_MATH_IMPLEMENTATION |
|
|
||||||
**1.11.1** | Added HMM_PREFIX macro to a few functions that were missing it. |
|
**1.11.1** | Added HMM_PREFIX macro to a few functions that were missing it. |
|
||||||
**1.11.0** | Added ability to customize or remove the default `HMM_` prefix on function names by defining a macro called `HMM_PREFIX(name)`. |
|
**1.11.0** | Added ability to customize or remove the default `HMM_` prefix on function names by defining a macro called `HMM_PREFIX(name)`. |
|
||||||
**1.10.1** | Removed stdint.h, this doesn't exist on some really old compilers and we didn't really use it anyways. |
|
**1.10.1** | Removed stdint.h, this doesn't exist on some really old compilers and we didn't really use it anyways. |
|
||||||
|
|||||||
@@ -199,32 +199,3 @@ TEST(Subtraction, Quaternion)
|
|||||||
EXPECT_FLOAT_EQ(q1.W, -4.0f);
|
EXPECT_FLOAT_EQ(q1.W, -4.0f);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifdef __cplusplus
|
|
||||||
TEST(UnaryMinus, Vec2)
|
|
||||||
{
|
|
||||||
hmm_vec2 VectorOne = {1.0f, 2.0f};
|
|
||||||
hmm_vec2 Result = -VectorOne;
|
|
||||||
EXPECT_FLOAT_EQ(Result.X, -1.0f);
|
|
||||||
EXPECT_FLOAT_EQ(Result.Y, -2.0f);
|
|
||||||
}
|
|
||||||
|
|
||||||
TEST(UnaryMinus, Vec3)
|
|
||||||
{
|
|
||||||
hmm_vec3 VectorOne = {1.0f, 2.0f, 3.0f};
|
|
||||||
hmm_vec3 Result = -VectorOne;
|
|
||||||
EXPECT_FLOAT_EQ(Result.X, -1.0f);
|
|
||||||
EXPECT_FLOAT_EQ(Result.Y, -2.0f);
|
|
||||||
EXPECT_FLOAT_EQ(Result.Z, -3.0f);
|
|
||||||
}
|
|
||||||
|
|
||||||
TEST(UnaryMinus, Vec4)
|
|
||||||
{
|
|
||||||
hmm_vec4 VectorOne = {1.0f, 2.0f, 3.0f, 4.0f};
|
|
||||||
hmm_vec4 Result = -VectorOne;
|
|
||||||
EXPECT_FLOAT_EQ(Result.X, -1.0f);
|
|
||||||
EXPECT_FLOAT_EQ(Result.Y, -2.0f);
|
|
||||||
EXPECT_FLOAT_EQ(Result.Z, -3.0f);
|
|
||||||
EXPECT_FLOAT_EQ(Result.W, -4.0f);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|||||||
Reference in New Issue
Block a user