[WINESYNC] d3dx9/tests: Improve D3DXMatrixInverse() test a tiny bit.

Signed-off-by: Matteo Bruni <mbruni@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>

wine commit id 5c052b699e7ac5c0e4f2324fe31e2d022dcf4bb5 by Matteo Bruni <mbruni@codeweavers.com>
This commit is contained in:
winesync 2020-09-21 22:50:19 +02:00 committed by Jérôme Gardou
parent b238e9688c
commit 9b602dbdc9
2 changed files with 7 additions and 4 deletions

View file

@ -321,11 +321,11 @@ static void D3DXMatrixTest(void)
D3DXMATRIX expectedmat, gotmat, mat, mat2, mat3;
BOOL expected, got, equal;
float angle, determinant;
D3DXMATRIX *funcpointer;
D3DXPLANE plane;
D3DXQUATERNION q, r;
D3DXVECTOR3 at, axis, eye, last;
D3DXVECTOR4 light;
D3DXMATRIX *ret;
U(mat).m[0][1] = 5.0f; U(mat).m[0][2] = 7.0f; U(mat).m[0][3] = 8.0f;
U(mat).m[1][0] = 11.0f; U(mat).m[1][2] = 16.0f; U(mat).m[1][3] = 33.0f;
@ -410,8 +410,11 @@ static void D3DXMatrixTest(void)
expect_matrix(&expectedmat, &gotmat, 1);
equal = compare_float(determinant, -147888.0f, 0);
ok(equal, "Got unexpected determinant %.8e.\n", determinant);
funcpointer = D3DXMatrixInverse(&gotmat,NULL,&mat2);
ok(funcpointer == NULL, "Expected: %p, Got: %p\n", NULL, funcpointer);
determinant = 5.0f;
ret = D3DXMatrixInverse(&gotmat, &determinant, &mat2);
ok(!ret, "Unexpected return value %p.\n", ret);
expect_matrix(&expectedmat, &gotmat, 1);
ok(compare_float(determinant, 5.0f, 0), "Unexpected determinant %.8e.\n", determinant);
/*____________D3DXMatrixIsIdentity______________*/
expected = FALSE;

View file

@ -15,4 +15,4 @@ files: {include/d3dx9.h: sdk/include/dxsdk/d3dx9.h, include/d3dx9anim.h: sdk/inc
include/d3dx9mesh.h: sdk/include/dxsdk/d3dx9mesh.h, include/d3dx9of.h: sdk/include/dxsdk/d3dx9of.h,
include/d3dx9shader.h: sdk/include/dxsdk/d3dx9shader.h, include/d3dx9shape.h: sdk/include/dxsdk/d3dx9shape.h,
include/d3dx9tex.h: sdk/include/dxsdk/d3dx9tex.h, include/d3dx9xof.h: sdk/include/dxsdk/d3dx9xof.h}
tags: {wine: aec8e12a3d71272b31aa8b5b075fe1cd88517c92}
tags: {wine: 5c052b699e7ac5c0e4f2324fe31e2d022dcf4bb5}