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
66693a6e
Commit
66693a6e
authored
Jun 06, 2011
by
Dylan Smith
Committed by
Alexandre Julliard
Jun 07, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9: Implement D3DXLoadMeshHierarchyFromX.
parent
bbc009f4
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
62 additions
and
2 deletions
+62
-2
d3dx9_36.spec
dlls/d3dx9_36/d3dx9_36.spec
+2
-2
mesh.c
dlls/d3dx9_36/mesh.c
+60
-0
No files found.
dlls/d3dx9_36/d3dx9_36.spec
View file @
66693a6e
...
...
@@ -173,9 +173,9 @@
@ stub D3DXLoadMeshFromXResource(long ptr ptr long ptr ptr ptr ptr ptr ptr)
@ stub D3DXLoadMeshFromXW(ptr long ptr ptr ptr ptr ptr ptr)
@ stub D3DXLoadMeshFromXof(ptr long ptr ptr ptr ptr ptr ptr)
@ st
ub D3DXLoadMeshHierarchyFromXA(p
tr long ptr ptr ptr ptr ptr)
@ st
dcall D3DXLoadMeshHierarchyFromXA(s
tr long ptr ptr ptr ptr ptr)
@ stdcall D3DXLoadMeshHierarchyFromXInMemory(ptr long long ptr ptr ptr ptr ptr)
@ st
ub D3DXLoadMeshHierarchyFromXW(p
tr long ptr ptr ptr ptr ptr)
@ st
dcall D3DXLoadMeshHierarchyFromXW(ws
tr long ptr ptr ptr ptr ptr)
@ stub D3DXLoadPatchMeshFromXof(ptr long ptr ptr ptr long ptr)
@ stub D3DXLoadPRTBufferFromFileA(ptr ptr)
@ stub D3DXLoadPRTBufferFromFileW(ptr ptr)
...
...
dlls/d3dx9_36/mesh.c
View file @
66693a6e
...
...
@@ -2724,6 +2724,66 @@ cleanup:
return
hr
;
}
HRESULT
WINAPI
D3DXLoadMeshHierarchyFromXA
(
LPCSTR
filename
,
DWORD
options
,
LPDIRECT3DDEVICE9
device
,
LPD3DXALLOCATEHIERARCHY
alloc_hier
,
LPD3DXLOADUSERDATA
load_user_data
,
LPD3DXFRAME
*
frame_hierarchy
,
LPD3DXANIMATIONCONTROLLER
*
anim_controller
)
{
HRESULT
hr
;
int
len
;
LPWSTR
filenameW
;
TRACE
(
"(%s, %x, %p, %p, %p, %p, %p)
\n
"
,
debugstr_a
(
filename
),
options
,
device
,
alloc_hier
,
load_user_data
,
frame_hierarchy
,
anim_controller
);
if
(
!
filename
)
return
D3DERR_INVALIDCALL
;
len
=
MultiByteToWideChar
(
CP_ACP
,
0
,
filename
,
-
1
,
NULL
,
0
);
filenameW
=
HeapAlloc
(
GetProcessHeap
(),
0
,
len
*
sizeof
(
WCHAR
));
if
(
!
filenameW
)
return
E_OUTOFMEMORY
;
MultiByteToWideChar
(
CP_ACP
,
0
,
filename
,
-
1
,
filenameW
,
len
);
hr
=
D3DXLoadMeshHierarchyFromXW
(
filenameW
,
options
,
device
,
alloc_hier
,
load_user_data
,
frame_hierarchy
,
anim_controller
);
HeapFree
(
GetProcessHeap
(),
0
,
filenameW
);
return
hr
;
}
HRESULT
WINAPI
D3DXLoadMeshHierarchyFromXW
(
LPCWSTR
filename
,
DWORD
options
,
LPDIRECT3DDEVICE9
device
,
LPD3DXALLOCATEHIERARCHY
alloc_hier
,
LPD3DXLOADUSERDATA
load_user_data
,
LPD3DXFRAME
*
frame_hierarchy
,
LPD3DXANIMATIONCONTROLLER
*
anim_controller
)
{
HRESULT
hr
;
DWORD
size
;
LPVOID
buffer
;
TRACE
(
"(%s, %x, %p, %p, %p, %p, %p)
\n
"
,
debugstr_w
(
filename
),
options
,
device
,
alloc_hier
,
load_user_data
,
frame_hierarchy
,
anim_controller
);
if
(
!
filename
)
return
D3DERR_INVALIDCALL
;
hr
=
map_view_of_file
(
filename
,
&
buffer
,
&
size
);
if
(
FAILED
(
hr
))
return
D3DXERR_INVALIDDATA
;
hr
=
D3DXLoadMeshHierarchyFromXInMemory
(
buffer
,
size
,
options
,
device
,
alloc_hier
,
load_user_data
,
frame_hierarchy
,
anim_controller
);
UnmapViewOfFile
(
buffer
);
return
hr
;
}
static
HRESULT
filedata_get_name
(
IDirectXFileData
*
filedata
,
char
**
name
)
{
HRESULT
hr
;
...
...
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