d3dx8: Correct trace minimum in D3DXQuaternionRotationMatrix with tests 1/2

Luis Busquets luis.busquets at ilidium.com
Tue Aug 5 11:53:04 CDT 2008


Currently the function D3DXQuaternionRotationMatrix evaluates the values 
of the components of the vector from the "trace" whenever this is bigger 
than 0. The literacy discourages this as the error can be very big if 
trace is near 0. From the tests implemented in this patch, it comes out 
that the value with whom trace is compared is 1.0f. Therefore, this 
patch adds tests to verify the cases where trace is between 0.0 and 2.0 
to ensure the expected result.


---
  dlls/d3dx8/math.c       |    2 +-
  dlls/d3dx8/tests/math.c |  100 
+++++++++++++++++++++++++++++++++++++++++++++++
  2 files changed, 101 insertions(+), 1 deletions(-)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 005d4005b2dea96de03ed79371776dbfa421d148.diff
Type: text/x-patch
Size: 8173 bytes
Desc: not available
Url : http://www.winehq.org/pipermail/wine-patches/attachments/20080805/7c8bcdd4/attachment.bin 


More information about the wine-patches mailing list