These changes were all made by @dev-dwarf. Many thanks for his work on this!
* Renaming
* First Pass on 2.0UpdateTool
* Another pass on UpdateTool, changed name
* Another pass on UpdateTool, changed name
* Do Renaming
* Working on Angles Consistency
* Passing Coverage
* Remove unused arc-tangent functions
* Change macro defaults
By default if user is overriding trig functions assume their input and internal units are the same.
* wrap in AngleDeg instead of AngleRad
* Remove HMM_PREFIX configuration
* Fix for Slerp
https://discord.com/channels/239737791225790464/489148972305350656/1055167647274246265
Justified by most implementations of Slerp. EX: http://number-none.com/product/Understanding%20Slerp,%20Then%20Not%20Using%20It/
* Handedness Changes
* More renaming. C11 _Generics
Generics enable by default when available (see lines 97-104). User can also force them by defining HANDMADE_MATH_C11_GENERICS
Also fixed some missed things w.r.t renaming. My old tool didn't catch cases like HMM_MultiplyVec3f needing to be HMM_MulV3F instead of HMM_MulV3f.
* Reuse more SSE codepaths for Quaternions
Also improved quaternion tests. More work could be done here, see discussion here about optimizing slerp: https://discord.com/channels/239737791225790464/489148972305350656/1055167647274246265
* Just saving these alternate versions of SLerp
* Reduce V4/M4 Linear Comb. codepaths
* Simple implementation of 2x2 and 3x3 basic matrix operations.
Also renamed Transpose to TransposeM4, so that we can have TransposeM2,M3
* Norm is dead! Long live Norm!
As can be seen from the tests, precision has declined quite a bit from using the FastNorm implementations for various things. We can only guarantee about 0.001f precision for anything where a norm happens now. If this is undesired we can change back easily.
* Started work on Matrix Inverses
TODO: Tests for simple 4x4 Inverses
* Matrix Inverses + Tests
* Generics for Matrices and Rename MXd/f functions
* Fixes + Better Output for UpdateTool
* I think I count as a contributor : )
* Ported UpdateTool, Inlined my library code.
* Moved tool to different repo
https://github.com/dev-dwarf/HMM2.0UpdateTool
* Remove small test change
* Found some more references to atan functions
* Standardize angle function names, use short names
* Remove other slerp comments
* woops that wasnt meant to be commited.
* Finish changing ToRadians to ToRad
* Fix [] overloads
per https://discord.com/channels/239737791225790464/600063880533770251/1051600188302692402
* Tests for 2x2, 3x3 Matrices and Other Matrix Ops
* Add an option to use Z: [0, 1] range for projection matrices.
This will make HMM more convenient to use with other graphics APIs such as Direct3d and Metal.
* Update test imports
* #if should've been #ifdef!
* Implement requested changes
Building with clang 12 with -Wextra, the following two warnings are
generated:
```
HandmadeMath.h:1167:25: warning: missing field 'Y' initializer [-Wmissing-field-initializers]
hmm_vec2 Result = {0};
^
HandmadeMath.h:1167:24: warning: suggest braces around initialization of subobject [-Wmissing-braces]
```
This expands the `-Wmissing-braces` ignore to also target clang, and adds an
ignore for `-Wmissing-field-initializers`
* Add coverage features and add it, laboriously, to everything
* Fix easy tests
* Add tests for != operators
* Clean up test framework a little
* Add documentation of coverage macros
* Fix tests for mat4 to quaternion
* Slightly improve formatting of coverage output
* Trailing whitespace must die
* Add array subscript operators for all types
* Taking the parameter for the operator[] as a reference. This should allow it to be inlined
* I guess you can't do that.
* Update version and readme
* Convert everything to new inline scheme
* Add both extern and inline for some SSE vs. non-SSE functions
Some functions had nice, compact SSE implementations but bulky non-SSE
implementations, so this commit inlines just the implementations that make
sense. Also updated documentation.
* Convert HINLINE and HEXTERN to HMM_INLINE and HMM_EXTERN
* Fixed bug when using handmademath in C mode
* SSEd vec4 operations
* Fixed hmm_vec4 for non-sse builds. Added SSE option for HMM_Vec4 to load in one instruction
* Whoops. We were loading in the wrong order
* SSEd more things
* SSEd more functions
* Minor fixups
* SSE'd hmm_vec4 initialization
* Removed zeroing
* Vector normalization should be zero'd
* Removed old comments
* SSEd HMM_MultiplyMat4 and HMM_Transpose. And added HMM_LinearCombineSSE
* Maybe Travis doesn't support SSE?
* Fix compile process so the SSE option is consistently defined
* Fix link error
* Documentation
* Added function prototype for operator ==
* Added != operator for hmm_vec2, hmm_vec3, hmm_vec4
* Add C versions of equality checks
Also made the C++ tests actually run...😳
* Update documentation
* Handle zero-vector normalization.
When normalizing a vectors, we have to check whether vector length is
not zero, to avoid dividing by zero when normalizing zero-vectors.
* Test for normalization of zero vectors
* at one place HANDMADE_NO_SSE instead of HANDMADE_MATH_NO_SSE was used
* introduce HANDMADE_MATH__USE_SSE for the SSE #ifdefs throughout code
- use #ifdef HANDMADE_MATH_NO_SSE at only one place
* only use SSE (#define HANDMADE_MATH__USE_SSE) if the targetplatform
actually supports it
=> users don't have to #define HANDMADE_MATH_NO_SSE on ARM etc
* at one place HMM_SqrtF instead of HMM_SquareRootF was used
* Switch to custom unit testing that is compatible with C
* Remove Google Test framework
* Attempt to fix missing math functions
* Link against C math library
* Try forcing c99 again
* Include -lm at compile time
* Move -lm argument to the end
* Update README and gitignore
* Various changes, and started work on Quaternions
* Worked on Quaternions (#46)
* Working on quaternions
* Finished operations, onto slerp
* Working on slerp
* Finished slerp implementation, next is NLerp
* Cleaned HandmadeMath.cpp
* Removed gbmath includes
* fixed minor issue.
* Fixed function names
* Fixed DotQuat call
* Did a style check
* Double Style Check
* Triple Style Check
* Fixed all the bullshit I did wrong
* Fixed more bs
* Added new functions
* Finished function implements
* Fixed some compile errors
* Fixed UTF-8 Error
* Added in most operator overrides
* Changed instances of HMM_PI to HMM_Pi32
* Fixed a warning
* Fixed a major issue with quaternion to matrix function where rotations about the y axis caused strange warping.
* Revert "Fixed a warning"
This reverts commit 043decab0d.
* Revert repo
* Fixed Quaternion to Matrix function.
* Fixed some prevalent issues, and now pulls triganometric funcitions from the std instead of implementing them.
* Fixed tab formatting, added in reverse multiplication function with Quaternions
* Removed error suppression cleanup, as it was causing more warnings. . .
* Added documentation
* Changed ATanf2 to ATan2f
* Fixed some typos and added additional documentation (#48)
* Add tests for quaternions
* Remove (very wrong) quaternion division in favor of multiplying by inverse
* Put back newlines at ends of files
* Make tweaks for PR
* Add assigning arithmetic operators for quaternions
* Add NLerp
Just to make Jonathan Blow happy: http://number-none.com/product/Understanding%20Slerp,%20Then%20Not%20Using%20It/
* Rearrange parameters of HMM_Slerp
It now matches HMM_Lerp and HMM_NLerp.
* Update README.md