Updated README.md and Fixed SSE code

This commit is contained in:
Zak Strange
2016-08-25 16:11:03 -07:00
parent 08baa85448
commit b638056bcd
2 changed files with 19 additions and 9 deletions

View File

@@ -1,5 +1,5 @@
/*
HandmadeMath.h v0.5.1
HandmadeMath.h v0.5.2
This is a single header file with a bunch of useful functions for
basic game math operations.
@@ -119,7 +119,9 @@
0.5.1
(*) Ensured column-major order for matrices throughout
(*) Fixed HMM_Translate producing row-major matrices
0.5.2
(*) Fixed SSE code in HMM_SqrtF
(*) Fixed SSE code in HMM_RSqrtF
LICENSE
@@ -533,9 +535,9 @@ HMM_SqrtF(float Value)
#ifdef HANDMADE_MATH_NO_SSE
Result = sqrtf(Value);
#else
__m128 In = _mm_load_ss(&Value);
__m128 In = _mm_set_ss(Value);
__m128 Out = _mm_sqrt_ss(In);
_mm_store_ss(&Result, Out);
Result = _mm_cvtss_f32(Out);
#endif
return(Result);
@@ -549,9 +551,9 @@ HMM_RSqrtF(float Value)
#ifdef HANDMADE_MATH_NO_SSE
Result = 1.0f/HMM_SqrtF(Value);
#else
__m128 In = _mm_load_ss(&Value);
__m128 In = _mm_set_ss(Value);
__m128 Out = _mm_rsqrt_ss(In);
_mm_store_ss(&Result, Out);
Result = _mm_cvtss_f32(Out);
#endif
return(Result);

View File

@@ -1,20 +1,28 @@
# Handmade-Math
------
Single-file public domain game math library for C/C++
Single-file cross-platform public domain game math library for C/C++
Version | Changes |
----------------|----------------|
**0.5.2** | Fixed SSE code in HMM_SqrtF and HMM_RSqrtF |
**0.5.1** | Fixed HMM_Translate producing row-major matrices, ensured column-major order for matrices throughout |
**0.5** | Added scalar operations on vectors and matrices, added += and -= for hmm_mat4, reconciled headers and implementations, tidied up in general |
**0.4** | Added SSE Optimized HMM_SqrtF, HMM_RSqrtF, Removed use of CRT |
**0.4** | Added SSE Optimized HMM_SqrtF, HMM_RSqrtF, Removed use of C Runtime |
**0.3** | Added +=,-=, *=, /= for hmm_vec2, hmm_vec3, hmm_vec4 |
**0.2b** | Disabled warning C4201 on MSVC, Added 64bit percision on HMM_PI |
**0.2a** | Prefixed Macros |
**0.2** | Updated Documentation, Fixed C Compliance, Prefixed all functions, and added better operator overloading |
**0.1** | Initial Version |
_ID: In Development_
-----
_This library is free and will stay free, but if you would like to support development, or you are a company using HandmadeMath, please consider financial support._
![alt text](https://cloud.githubusercontent.com/assets/8225057/5990484/70413560-a9ab-11e4-8942-1a63607c0b00.png "Logo Title Text 1")
## FAQ