Commit Graph

48 Commits

Author SHA1 Message Date
Ben Visness
aaa767bf0b Update README.md 2023-02-20 13:29:24 -06:00
Ben Visness
beb837a3c6 Tweak docs, add tests, find bugs 2023-02-02 19:18:24 -06:00
Ben Visness
f106a0f5f3 Style and docs pass for release
Remove V2I, V3I, V4I (and style changes)

Totally useless.

Add update tool, update docs

Tweak docs

Create ci.yml

Big style pass

Maybe fix CI on Windows

Report coverage errors

Fix a missing coverage case

Try setting up MSVC another way

Update readmes

Fix remaining use of the name UpdateTool
2023-01-22 21:46:22 -06:00
Zak Strange
ba5405ac0f Update README.md 2021-08-31 17:11:42 -07:00
Zak Strange
d69a859d73 Fully inlined HandmadeMath.h (#139)
* Fully inlined HandmadeMath.h, renamed test.bat to run_test_msvc.bat, and introduced run_test_clang.bat

* General Cleanup
2021-08-31 17:10:46 -07:00
Tim Gates
5f816bf9b3 docs: fix simple typo, percision -> precision (#137)
There is a small typo in README.md.

Should read `precision` rather than `percision`.
2021-08-31 09:22:29 -07:00
Ben Visness
43afc87fa7 Remove non-functioning issue link 2021-03-24 10:04:17 -05:00
Ben Visness
5bbac2167e Update version and changelog 2021-03-24 10:02:08 -05:00
Zak Strange
1d82b4f0bc Unary minus vectors (#130)
* Unary Minus operator for vec2, vec3, and vec4

* Update README.md

Co-authored-by: zak <zak@DESKTOP-V1AQ0IT>
2021-03-06 18:39:17 -06:00
Ben Visness
ddb9971e71 Update README 2020-07-09 08:51:53 -05:00
Ben Visness
c825fe48cf Update version and release notes 2020-04-06 10:02:16 -05:00
Zak Strange
785f19d4a7 Removed use of stdint.h (#110) 2020-01-11 17:13:09 -08:00
Ben Visness
93e56be543 Use vertical instead of horizontal FOV in HMM_Perspective (#101)
* Use vertical instead of horizontal FOV

* Update readme

* Fix tests
2019-07-10 11:29:51 -05:00
Ben Visness
45c91702a9 Added SSE support for Quaternion operations (#97) (#98)
* Added SSE support for Quaternion operations (#97)

* Added SSE support for Quaternion operations

O2
| Function    |     SSE         |      NO SSE      |
====================================================
| Inverse     |     163 (0.89s) |      165 (1.89s) |
| NLerp       |     330 (1.70s) |      330 (1.75s) |
| Normalize   |     169 (1.03s) |      169 (1.06s) |
| Dot         |     22  (1.15s) |      23  (1.14s) |
| DivF        |     23  (0.72s) |      23  (0.82s) |
| MulF        |     22  (0.75s) |      22  (0.79s) |
| Mul         |     24  (1.14s) |      23  (1.24s) |
| Sub         |     23  (1.17s) |      37  (1.20s) |
| Add         |     23  (1.20s) |      24  (1.19s) |



O0
| Function    |     SSE         |      NO SSE      |
====================================================
| Inverse     |     394 (1.62s) |      430 (3.05s) |
| NLerp       |     694 (2.71s) |      1035(4.81s) |
| Normalize   |     374 (1.58s) |      412 (2.95s) |
| Dot         |     81  (1.83s) |      23  (2.50s) |
| DivF        |     61  (1.12s) |      25  (2.37s) |
| MulF        |     58  (1.09s) |      23  (2.31s) |
| Mul         |     94  (1.97s) |      42  (2.88s) |
| Sub         |     75  (1.83s) |      23  (2.82s) |
| Add         |     75  (1.81s) |      23  (2.81s) |

* Fixed quaternion multiplication

Old quaternion multiplication had a bug, this is a different approach.

* Added release notes and version for 1.9.0
2019-03-11 13:12:48 -05:00
Ben Visness
f7c8e1f7d1 Add fast vector normalization (#94)
* Add fast normalization routines

* Update readme and remove version history from main file

* Update version at top of file
2018-11-29 22:02:41 -08:00
Ben Visness
5ca1d58b36 Improve grammar/spelling 2018-11-29 13:21:05 -06:00
Zak Strange
5bf727dbd5 Removed copy in operator[] (#93)
* Removed copy in operator[]

* Updated version info
2018-11-29 09:32:12 -08:00
Ben Visness
295f6c476f Rename Rows to Columns on hmm_mat4 (#91) 2018-08-17 11:02:44 -07:00
Ben Visness
4e2f47db55 Add array subscript operators for all types (#88)
* 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
2018-06-10 15:26:48 -04:00
Ben Visness
bee0e0c569 WIP: Properly initialize all elements of LookAt matrix (#84)
* Properly initialize all elements of LookAt matrix

* Update version and readme

* Add a test for LookAt

good enough
2018-06-03 18:42:09 -05:00
Ben Visness
52fd5cceb4 Update README.md 2017-10-31 19:28:59 -05:00
Ben Visness
8e67482295 Update README.md 2017-10-31 11:07:07 -05:00
Ben Visness
250c38e845 Update README.md 2017-10-31 11:01:31 -05:00
Ben Visness
4981d5ab89 Convert everything to new inline scheme (#57) (#72)
* 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
2017-10-31 10:16:36 -05:00
Ben Visness
575fcb767d Update README.md 2017-10-31 10:06:22 -05:00
strangezak
53bc939d8e Updated email 2017-10-04 09:40:31 -07:00
Ben Visness
7eb4ae1846 Update README for 1.4.0 2017-10-02 11:17:11 -05:00
Ben Visness
afd726ab0b Automatically include C++ definitions (#67) 2017-08-02 10:12:06 -05:00
Ben Visness
efd9f2f4b7 Matrix Multiply SSE (#65)
* 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
2017-07-16 21:19:34 -07:00
Ben Visness
c8ada18370 Update README for 1.1.5 2017-06-21 09:31:20 -05:00
Ben Visness
924ee43923 Update history to include @DanielGibson's SSE fixes 2017-06-13 11:39:42 -05:00
Ben Visness
440b885d59 Update version to 1.1.4 2017-06-13 11:26:46 -05:00
Ben Visness
cf606db217 Test in both C and C++ (#58)
* 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
2017-04-07 08:47:54 -05:00
Ben Visness
67b84dece7 Fix invalid HMMDEF's in function definitions (#56)
* Fix invalid HMMDEF's in function definitions

* Update version number and readme
2017-03-29 16:19:25 -07:00
Ben Visness
ad3039186d Initial quaternion implementation (#49)
* 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
2017-01-04 16:25:12 -08:00
Zak Strange
aed68cc894 Version 1.0 2016-11-02 14:27:13 -07:00
Zak Strange
14f7d13cba Updated README.md 2016-09-06 11:22:35 -07:00
Zak Strange
86dfb43c1f Updated README.md 2016-08-30 13:55:14 -07:00
Ben Visness
340f0bddbf Merge remote-tracking branch 'upstream/master' into unit-tests
# Conflicts:
#	README.md
2016-08-29 11:35:29 -05:00
Zak Strange
c9107ad5de Fixed README.md links 2016-08-28 10:24:35 -07:00
Zak Strange
b638056bcd Updated README.md and Fixed SSE code 2016-08-25 16:11:03 -07:00
Ben Visness
603dcc2f4a Add Google Test setup and one unit test 2016-08-25 16:04:42 -05:00
Ben Visness
fa9f401844 Update README.md 2016-08-25 14:22:46 -05:00
Ben Visness
c9ec065fd5 Add documentation for v0.5 2016-08-23 18:20:59 -05:00
Zak Strange
ed4aef49e1 0.4 - Removed use of CRT 2016-08-20 09:13:37 -07:00
Zak Strange
80d2492d86 0.3 - Added +=,-=, *=, /= for hmm_vec2, hmm_vec3, hmm_vec4 2016-08-19 20:28:32 -07:00
StrangeZak
cd4f29a703 Added SSE Optimization HMM_Rsqrtf, and HMM_Sqrtf. Removed all direct calls to the CRT, and updated README.md 2016-07-30 15:18:45 -07:00
=
c4a8f1a2b1 Added README.md 2016-01-22 19:30:24 -07:00