Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
3e24dc64
Commit
3e24dc64
authored
Sep 28, 2012
by
Rico Schüller
Committed by
Alexandre Julliard
Sep 28, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9: Use float functions in D3DXMatrixRotationAxis().
parent
945e81b3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
27 additions
and
15 deletions
+27
-15
math.c
dlls/d3dx9_36/math.c
+27
-15
No files found.
dlls/d3dx9_36/math.c
View file @
3e24dc64
...
...
@@ -551,24 +551,36 @@ D3DXMATRIX* WINAPI D3DXMatrixReflect(D3DXMATRIX *pout, CONST D3DXPLANE *pplane)
return
pout
;
}
D3DXMATRIX
*
WINAPI
D3DXMatrixRotationAxis
(
D3DXMATRIX
*
pout
,
CONST
D3DXVECTOR3
*
p
v
,
FLOAT
angle
)
D3DXMATRIX
*
WINAPI
D3DXMatrixRotationAxis
(
D3DXMATRIX
*
out
,
const
D3DXVECTOR3
*
v
,
FLOAT
angle
)
{
D3DXVECTOR3
v
;
D3DXVECTOR3
nv
;
FLOAT
sangle
,
cangle
,
cdiff
;
TRACE
(
"
(%p, %p, %f)
\n
"
,
pout
,
p
v
,
angle
);
TRACE
(
"
out %p, v %p, angle %f
\n
"
,
out
,
v
,
angle
);
D3DXVec3Normalize
(
&
v
,
pv
);
D3DXMatrixIdentity
(
pout
);
pout
->
u
.
m
[
0
][
0
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
x
*
v
.
x
+
cos
(
angle
);
pout
->
u
.
m
[
1
][
0
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
x
*
v
.
y
-
sin
(
angle
)
*
v
.
z
;
pout
->
u
.
m
[
2
][
0
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
x
*
v
.
z
+
sin
(
angle
)
*
v
.
y
;
pout
->
u
.
m
[
0
][
1
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
y
*
v
.
x
+
sin
(
angle
)
*
v
.
z
;
pout
->
u
.
m
[
1
][
1
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
y
*
v
.
y
+
cos
(
angle
);
pout
->
u
.
m
[
2
][
1
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
y
*
v
.
z
-
sin
(
angle
)
*
v
.
x
;
pout
->
u
.
m
[
0
][
2
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
z
*
v
.
x
-
sin
(
angle
)
*
v
.
y
;
pout
->
u
.
m
[
1
][
2
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
z
*
v
.
y
+
sin
(
angle
)
*
v
.
x
;
pout
->
u
.
m
[
2
][
2
]
=
(
1
.
0
f
-
cos
(
angle
))
*
v
.
z
*
v
.
z
+
cos
(
angle
);
return
pout
;
D3DXVec3Normalize
(
&
nv
,
v
);
sangle
=
sinf
(
angle
);
cangle
=
cosf
(
angle
);
cdiff
=
1
.
0
f
-
cangle
;
out
->
u
.
m
[
0
][
0
]
=
cdiff
*
nv
.
x
*
nv
.
x
+
cangle
;
out
->
u
.
m
[
1
][
0
]
=
cdiff
*
nv
.
x
*
nv
.
y
-
sangle
*
nv
.
z
;
out
->
u
.
m
[
2
][
0
]
=
cdiff
*
nv
.
x
*
nv
.
z
+
sangle
*
nv
.
y
;
out
->
u
.
m
[
3
][
0
]
=
0
.
0
f
;
out
->
u
.
m
[
0
][
1
]
=
cdiff
*
nv
.
y
*
nv
.
x
+
sangle
*
nv
.
z
;
out
->
u
.
m
[
1
][
1
]
=
cdiff
*
nv
.
y
*
nv
.
y
+
cangle
;
out
->
u
.
m
[
2
][
1
]
=
cdiff
*
nv
.
y
*
nv
.
z
-
sangle
*
nv
.
x
;
out
->
u
.
m
[
3
][
1
]
=
0
.
0
f
;
out
->
u
.
m
[
0
][
2
]
=
cdiff
*
nv
.
z
*
nv
.
x
-
sangle
*
nv
.
y
;
out
->
u
.
m
[
1
][
2
]
=
cdiff
*
nv
.
z
*
nv
.
y
+
sangle
*
nv
.
x
;
out
->
u
.
m
[
2
][
2
]
=
cdiff
*
nv
.
z
*
nv
.
z
+
cangle
;
out
->
u
.
m
[
3
][
2
]
=
0
.
0
f
;
out
->
u
.
m
[
0
][
3
]
=
0
.
0
f
;
out
->
u
.
m
[
1
][
3
]
=
0
.
0
f
;
out
->
u
.
m
[
2
][
3
]
=
0
.
0
f
;
out
->
u
.
m
[
3
][
3
]
=
1
.
0
f
;
return
out
;
}
D3DXMATRIX
*
WINAPI
D3DXMatrixRotationQuaternion
(
D3DXMATRIX
*
pout
,
CONST
D3DXQUATERNION
*
pq
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment