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
8435f6f0
Commit
8435f6f0
authored
Mar 11, 2005
by
Oliver Stieber
Committed by
Alexandre Julliard
Mar 11, 2005
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change AddRef in queryInterface to IUnknown_AddRef.
Move ppVoulme to d3d9voloumeimpl structure. Some minor stylistic changes (making everything the same).
parent
898068f3
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
197 additions
and
69 deletions
+197
-69
basetexture.c
dlls/d3d9/basetexture.c
+17
-3
cubetexture.c
dlls/d3d9/cubetexture.c
+45
-17
indexbuffer.c
dlls/d3d9/indexbuffer.c
+20
-8
resource.c
dlls/d3d9/resource.c
+11
-1
surface.c
dlls/d3d9/surface.c
+17
-5
texture.c
dlls/d3d9/texture.c
+20
-14
vertexbuffer.c
dlls/d3d9/vertexbuffer.c
+17
-5
volume.c
dlls/d3d9/volume.c
+15
-5
volumetexture.c
dlls/d3d9/volumetexture.c
+34
-10
vshaderdeclaration.c
dlls/d3d9/vshaderdeclaration.c
+1
-1
No files found.
dlls/d3d9/basetexture.c
View file @
8435f6f0
...
@@ -22,16 +22,16 @@
...
@@ -22,16 +22,16 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DBaseTexture9 IUnknown parts follow: */
/* IDirect3DBaseTexture9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_QueryInterface
(
LPDIRECT3DBASETEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_QueryInterface
(
LPDIRECT3DBASETEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
))
{
I
Direct3DBaseTexture9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -65,73 +65,87 @@ ULONG WINAPI IDirect3DBaseTexture9Impl_Release(LPDIRECT3DBASETEXTURE9 iface) {
...
@@ -65,73 +65,87 @@ ULONG WINAPI IDirect3DBaseTexture9Impl_Release(LPDIRECT3DBASETEXTURE9 iface) {
/* IDirect3DBaseTexture9 IDirect3DResource9 Interface follow: */
/* IDirect3DBaseTexture9 IDirect3DResource9 Interface follow: */
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_GetDevice
(
LPDIRECT3DBASETEXTURE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_GetDevice
(
LPDIRECT3DBASETEXTURE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
}
}
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_SetPrivateData
(
LPDIRECT3DBASETEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_SetPrivateData
(
LPDIRECT3DBASETEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_SetPrivateData
(
This
->
wineD3DBaseTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DBaseTexture_SetPrivateData
(
This
->
wineD3DBaseTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_GetPrivateData
(
LPDIRECT3DBASETEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_GetPrivateData
(
LPDIRECT3DBASETEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GetPrivateData
(
This
->
wineD3DBaseTexture
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DBaseTexture_GetPrivateData
(
This
->
wineD3DBaseTexture
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_FreePrivateData
(
LPDIRECT3DBASETEXTURE9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_FreePrivateData
(
LPDIRECT3DBASETEXTURE9
iface
,
REFGUID
refguid
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_FreePrivateData
(
This
->
wineD3DBaseTexture
,
refguid
);
return
IWineD3DBaseTexture_FreePrivateData
(
This
->
wineD3DBaseTexture
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DBaseTexture9Impl_SetPriority
(
LPDIRECT3DBASETEXTURE9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DBaseTexture9Impl_SetPriority
(
LPDIRECT3DBASETEXTURE9
iface
,
DWORD
PriorityNew
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_SetPriority
(
This
->
wineD3DBaseTexture
,
PriorityNew
);
return
IWineD3DBaseTexture_SetPriority
(
This
->
wineD3DBaseTexture
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DBaseTexture9Impl_GetPriority
(
LPDIRECT3DBASETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DBaseTexture9Impl_GetPriority
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GetPriority
(
This
->
wineD3DBaseTexture
);
return
IWineD3DBaseTexture_GetPriority
(
This
->
wineD3DBaseTexture
);
}
}
void
WINAPI
IDirect3DBaseTexture9Impl_PreLoad
(
LPDIRECT3DBASETEXTURE9
iface
)
{
void
WINAPI
IDirect3DBaseTexture9Impl_PreLoad
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
IWineD3DBaseTexture_PreLoad
(
This
->
wineD3DBaseTexture
);
IWineD3DBaseTexture_PreLoad
(
This
->
wineD3DBaseTexture
);
return
;
return
;
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DBaseTexture9Impl_GetType
(
LPDIRECT3DBASETEXTURE9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DBaseTexture9Impl_GetType
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GetType
(
This
->
wineD3DBaseTexture
);
return
IWineD3DBaseTexture_GetType
(
This
->
wineD3DBaseTexture
);
}
}
/* IDirect3DBaseTexture9 Interface follow: */
/* IDirect3DBaseTexture9 Interface follow: */
DWORD
WINAPI
IDirect3DBaseTexture9Impl_SetLOD
(
LPDIRECT3DBASETEXTURE9
iface
,
DWORD
LODNew
)
{
DWORD
WINAPI
IDirect3DBaseTexture9Impl_SetLOD
(
LPDIRECT3DBASETEXTURE9
iface
,
DWORD
LODNew
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_SetLOD
(
This
->
wineD3DBaseTexture
,
LODNew
);
return
IWineD3DBaseTexture_SetLOD
(
This
->
wineD3DBaseTexture
,
LODNew
);
}
}
DWORD
WINAPI
IDirect3DBaseTexture9Impl_GetLOD
(
LPDIRECT3DBASETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DBaseTexture9Impl_GetLOD
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GetLOD
(
This
->
wineD3DBaseTexture
);
return
IWineD3DBaseTexture_GetLOD
(
This
->
wineD3DBaseTexture
);
}
}
DWORD
WINAPI
IDirect3DBaseTexture9Impl_GetLevelCount
(
LPDIRECT3DBASETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DBaseTexture9Impl_GetLevelCount
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GetLevelCount
(
This
->
wineD3DBaseTexture
);
return
IWineD3DBaseTexture_GetLevelCount
(
This
->
wineD3DBaseTexture
);
}
}
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_SetAutoGenFilterType
(
LPDIRECT3DBASETEXTURE9
iface
,
D3DTEXTUREFILTERTYPE
FilterType
)
{
HRESULT
WINAPI
IDirect3DBaseTexture9Impl_SetAutoGenFilterType
(
LPDIRECT3DBASETEXTURE9
iface
,
D3DTEXTUREFILTERTYPE
FilterType
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_SetAutoGenFilterType
(
This
->
wineD3DBaseTexture
,
FilterType
);
return
IWineD3DBaseTexture_SetAutoGenFilterType
(
This
->
wineD3DBaseTexture
,
FilterType
);
}
}
D3DTEXTUREFILTERTYPE
WINAPI
IDirect3DBaseTexture9Impl_GetAutoGenFilterType
(
LPDIRECT3DBASETEXTURE9
iface
)
{
D3DTEXTUREFILTERTYPE
WINAPI
IDirect3DBaseTexture9Impl_GetAutoGenFilterType
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GetAutoGenFilterType
(
This
->
wineD3DBaseTexture
);
return
IWineD3DBaseTexture_GetAutoGenFilterType
(
This
->
wineD3DBaseTexture
);
}
}
void
WINAPI
IDirect3DBaseTexture9Impl_GenerateMipSubLevels
(
LPDIRECT3DBASETEXTURE9
iface
)
{
void
WINAPI
IDirect3DBaseTexture9Impl_GenerateMipSubLevels
(
LPDIRECT3DBASETEXTURE9
iface
)
{
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
IDirect3DBaseTexture9Impl
*
This
=
(
IDirect3DBaseTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DBaseTexture_GenerateMipSubLevels
(
This
->
wineD3DBaseTexture
);
return
IWineD3DBaseTexture_GenerateMipSubLevels
(
This
->
wineD3DBaseTexture
);
}
}
...
...
dlls/d3d9/cubetexture.c
View file @
8435f6f0
...
@@ -2,7 +2,8 @@
...
@@ -2,7 +2,8 @@
* IDirect3DCubeTexture9 implementation
* IDirect3DCubeTexture9 implementation
*
*
* Copyright 2002-2005 Jason Edmeades
* Copyright 2002-2005 Jason Edmeades
* Raphael Junqueira
* Copyright 2002-2005 Raphael Junqueira
* Copyright 2005 Oliver Stieber
*
*
* This library is free software; you can redistribute it and/or
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* modify it under the terms of the GNU Lesser General Public
...
@@ -22,17 +23,17 @@
...
@@ -22,17 +23,17 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d9
);
/* IDirect3DCubeTexture9 IUnknown parts follow: */
/* IDirect3DCubeTexture9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_QueryInterface
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_QueryInterface
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DCubeTexture9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DCubeTexture9
))
{
I
Direct3DCubeTexture9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -57,6 +58,7 @@ ULONG WINAPI IDirect3DCubeTexture9Impl_Release(LPDIRECT3DCUBETEXTURE9 iface) {
...
@@ -57,6 +58,7 @@ ULONG WINAPI IDirect3DCubeTexture9Impl_Release(LPDIRECT3DCUBETEXTURE9 iface) {
TRACE
(
"(%p) : ReleaseRef to %ld
\n
"
,
This
,
ref
);
TRACE
(
"(%p) : ReleaseRef to %ld
\n
"
,
This
,
ref
);
if
(
ref
==
0
)
{
if
(
ref
==
0
)
{
TRACE
(
"Releasing child %p
\n
"
,
This
->
wineD3DCubeTexture
);
IWineD3DCubeTexture_Release
(
This
->
wineD3DCubeTexture
);
IWineD3DCubeTexture_Release
(
This
->
wineD3DCubeTexture
);
HeapFree
(
GetProcessHeap
(),
0
,
This
);
HeapFree
(
GetProcessHeap
(),
0
,
This
);
}
}
...
@@ -66,82 +68,97 @@ ULONG WINAPI IDirect3DCubeTexture9Impl_Release(LPDIRECT3DCUBETEXTURE9 iface) {
...
@@ -66,82 +68,97 @@ ULONG WINAPI IDirect3DCubeTexture9Impl_Release(LPDIRECT3DCUBETEXTURE9 iface) {
/* IDirect3DCubeTexture9 IDirect3DResource9 Interface follow: */
/* IDirect3DCubeTexture9 IDirect3DResource9 Interface follow: */
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetDevice
(
LPDIRECT3DCUBETEXTURE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetDevice
(
LPDIRECT3DCUBETEXTURE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
}
}
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_SetPrivateData
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_SetPrivateData
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_SetPrivateData
(
This
->
wineD3DCubeTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DCubeTexture_SetPrivateData
(
This
->
wineD3DCubeTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetPrivateData
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetPrivateData
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_GetPrivateData
(
This
->
wineD3DCubeTexture
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DCubeTexture_GetPrivateData
(
This
->
wineD3DCubeTexture
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_FreePrivateData
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_FreePrivateData
(
LPDIRECT3DCUBETEXTURE9
iface
,
REFGUID
refguid
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_FreePrivateData
(
This
->
wineD3DCubeTexture
,
refguid
);
return
IWineD3DCubeTexture_FreePrivateData
(
This
->
wineD3DCubeTexture
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DCubeTexture9Impl_SetPriority
(
LPDIRECT3DCUBETEXTURE9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DCubeTexture9Impl_SetPriority
(
LPDIRECT3DCUBETEXTURE9
iface
,
DWORD
PriorityNew
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_SetPriority
(
This
->
wineD3DCubeTexture
,
PriorityNew
);
return
IWineD3DCubeTexture_SetPriority
(
This
->
wineD3DCubeTexture
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DCubeTexture9Impl_GetPriority
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DCubeTexture9Impl_GetPriority
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_GetPriority
(
This
->
wineD3DCubeTexture
);
return
IWineD3DCubeTexture_GetPriority
(
This
->
wineD3DCubeTexture
);
}
}
void
WINAPI
IDirect3DCubeTexture9Impl_PreLoad
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
void
WINAPI
IDirect3DCubeTexture9Impl_PreLoad
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_PreLoad
(
This
->
wineD3DCubeTexture
);
return
IWineD3DCubeTexture_PreLoad
(
This
->
wineD3DCubeTexture
);
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DCubeTexture9Impl_GetType
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DCubeTexture9Impl_GetType
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_GetType
(
This
->
wineD3DCubeTexture
);
return
IWineD3DCubeTexture_GetType
(
This
->
wineD3DCubeTexture
);
}
}
/* IDirect3DCubeTexture9 IDirect3DBaseTexture9 Interface follow: */
/* IDirect3DCubeTexture9 IDirect3DBaseTexture9 Interface follow: */
DWORD
WINAPI
IDirect3DCubeTexture9Impl_SetLOD
(
LPDIRECT3DCUBETEXTURE9
iface
,
DWORD
LODNew
)
{
DWORD
WINAPI
IDirect3DCubeTexture9Impl_SetLOD
(
LPDIRECT3DCUBETEXTURE9
iface
,
DWORD
LODNew
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_SetLOD
(
This
->
wineD3DCubeTexture
,
LODNew
);
return
IWineD3DCubeTexture_SetLOD
(
This
->
wineD3DCubeTexture
,
LODNew
);
}
}
DWORD
WINAPI
IDirect3DCubeTexture9Impl_GetLOD
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DCubeTexture9Impl_GetLOD
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IDirect3DBaseTexture9Impl_GetLOD
((
LPDIRECT3DBASETEXTURE9
)
This
);
return
IDirect3DBaseTexture9Impl_GetLOD
((
LPDIRECT3DBASETEXTURE9
)
This
);
}
}
DWORD
WINAPI
IDirect3DCubeTexture9Impl_GetLevelCount
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DCubeTexture9Impl_GetLevelCount
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_GetLevelCount
(
This
->
wineD3DCubeTexture
);
return
IWineD3DCubeTexture_GetLevelCount
(
This
->
wineD3DCubeTexture
);
}
}
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_SetAutoGenFilterType
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DTEXTUREFILTERTYPE
FilterType
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_SetAutoGenFilterType
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DTEXTUREFILTERTYPE
FilterType
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_SetAutoGenFilterType
(
This
->
wineD3DCubeTexture
,
FilterType
);
return
IWineD3DCubeTexture_SetAutoGenFilterType
(
This
->
wineD3DCubeTexture
,
FilterType
);
}
}
D3DTEXTUREFILTERTYPE
WINAPI
IDirect3DCubeTexture9Impl_GetAutoGenFilterType
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
D3DTEXTUREFILTERTYPE
WINAPI
IDirect3DCubeTexture9Impl_GetAutoGenFilterType
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_GetAutoGenFilterType
(
This
->
wineD3DCubeTexture
);
return
IWineD3DCubeTexture_GetAutoGenFilterType
(
This
->
wineD3DCubeTexture
);
}
}
void
WINAPI
IDirect3DCubeTexture9Impl_GenerateMipSubLevels
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
void
WINAPI
IDirect3DCubeTexture9Impl_GenerateMipSubLevels
(
LPDIRECT3DCUBETEXTURE9
iface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_GenerateMipSubLevels
(
This
->
wineD3DCubeTexture
);
return
IWineD3DCubeTexture_GenerateMipSubLevels
(
This
->
wineD3DCubeTexture
);
}
}
/* IDirect3DCubeTexture9 Interface follow: */
/* IDirect3DCubeTexture9 Interface follow: */
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetLevelDesc
(
LPDIRECT3DCUBETEXTURE9
iface
,
UINT
Level
,
D3DSURFACE_DESC
*
pDesc
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetLevelDesc
(
LPDIRECT3DCUBETEXTURE9
iface
,
UINT
Level
,
D3DSURFACE_DESC
*
pDesc
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
WINED3DSURFACE_DESC
wined3ddesc
;
WINED3DSURFACE_DESC
wined3ddesc
;
UINT
tmpInt
=
-
1
;
UINT
tmpInt
=
-
1
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
...
@@ -159,8 +176,10 @@ HRESULT WINAPI IDirect3DCubeTexture9Impl_GetLevelDesc(LPDIRECT3DCUBETEXTURE9 ifa
...
@@ -159,8 +176,10 @@ HRESULT WINAPI IDirect3DCubeTexture9Impl_GetLevelDesc(LPDIRECT3DCUBETEXTURE9 ifa
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetCubeMapSurface
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
,
IDirect3DSurface9
**
ppCubeMapSurface
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_GetCubeMapSurface
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
,
IDirect3DSurface9
**
ppCubeMapSurface
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
HRESULT
hrc
=
D3D_OK
;
HRESULT
hrc
=
D3D_OK
;
IWineD3DSurface
*
mySurface
=
NULL
;
IWineD3DSurface
*
mySurface
=
NULL
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
hrc
=
IWineD3DCubeTexture_GetCubeMapSurface
(
This
->
wineD3DCubeTexture
,
FaceType
,
Level
,
&
mySurface
);
hrc
=
IWineD3DCubeTexture_GetCubeMapSurface
(
This
->
wineD3DCubeTexture
,
FaceType
,
Level
,
&
mySurface
);
if
(
hrc
==
D3D_OK
&&
NULL
!=
ppCubeMapSurface
)
{
if
(
hrc
==
D3D_OK
&&
NULL
!=
ppCubeMapSurface
)
{
IWineD3DCubeTexture_GetParent
(
mySurface
,
(
IUnknown
**
)
ppCubeMapSurface
);
IWineD3DCubeTexture_GetParent
(
mySurface
,
(
IUnknown
**
)
ppCubeMapSurface
);
...
@@ -171,16 +190,19 @@ HRESULT WINAPI IDirect3DCubeTexture9Impl_GetCubeMapSurface(LPDIRECT3DCUBETEXTURE
...
@@ -171,16 +190,19 @@ HRESULT WINAPI IDirect3DCubeTexture9Impl_GetCubeMapSurface(LPDIRECT3DCUBETEXTURE
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_LockRect
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
,
D3DLOCKED_RECT
*
pLockedRect
,
CONST
RECT
*
pRect
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_LockRect
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
,
D3DLOCKED_RECT
*
pLockedRect
,
CONST
RECT
*
pRect
,
DWORD
Flags
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_LockRect
(
This
->
wineD3DCubeTexture
,
FaceType
,
Level
,
pLockedRect
,
pRect
,
Flags
);
return
IWineD3DCubeTexture_LockRect
(
This
->
wineD3DCubeTexture
,
FaceType
,
Level
,
pLockedRect
,
pRect
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_UnlockRect
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_UnlockRect
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_UnlockRect
(
This
->
wineD3DCubeTexture
,
FaceType
,
Level
);
return
IWineD3DCubeTexture_UnlockRect
(
This
->
wineD3DCubeTexture
,
FaceType
,
Level
);
}
}
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_AddDirtyRect
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
CONST
RECT
*
pDirtyRect
)
{
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_AddDirtyRect
(
LPDIRECT3DCUBETEXTURE9
iface
,
D3DCUBEMAP_FACES
FaceType
,
CONST
RECT
*
pDirtyRect
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DCubeTexture_AddDirtyRect
(
This
->
wineD3DCubeTexture
,
FaceType
,
pDirtyRect
);
return
IWineD3DCubeTexture_AddDirtyRect
(
This
->
wineD3DCubeTexture
,
FaceType
,
pDirtyRect
);
}
}
...
@@ -212,37 +234,43 @@ IDirect3DCubeTexture9Vtbl Direct3DCubeTexture9_Vtbl =
...
@@ -212,37 +234,43 @@ IDirect3DCubeTexture9Vtbl Direct3DCubeTexture9_Vtbl =
};
};
/* IDirect3DDevice9 IDirect3DCubeTexture9 Methods follow: */
/* IDirect3DDevice9 IDirect3DCubeTexture9 Methods follow: */
HRESULT
WINAPI
IDirect3DDevice9Impl_CreateCubeTexture
(
LPDIRECT3DDEVICE9
iface
,
HRESULT
WINAPI
IDirect3DDevice9Impl_CreateCubeTexture
(
LPDIRECT3DDEVICE9
iface
,
UINT
EdgeLength
,
UINT
Levels
,
DWORD
Usage
,
UINT
EdgeLength
,
UINT
Levels
,
DWORD
Usage
,
D3DFORMAT
Format
,
D3DPOOL
Pool
,
D3DFORMAT
Format
,
D3DPOOL
Pool
,
IDirect3DCubeTexture9
**
ppCubeTexture
,
HANDLE
*
pSharedHandle
)
{
IDirect3DCubeTexture9
**
ppCubeTexture
,
HANDLE
*
pSharedHandle
)
{
IDirect3DCubeTexture9Impl
*
object
;
IDirect3DCubeTexture9Impl
*
object
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
HRESULT
hr
=
D3D_OK
;
HRESULT
hr
=
D3D_OK
;
TRACE
(
"(%p) : ELen(%d) Lvl(%d) Usage(%ld) fmt(%u), Pool(%d) Shared(%p)"
,
This
,
EdgeLength
,
Levels
,
Usage
,
Format
,
Pool
,
pSharedHandle
);
/* Allocate the storage for the device */
/* Allocate the storage for the device */
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
IDirect3DCubeTexture9Impl
));
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
NULL
==
object
)
{
if
(
NULL
==
object
)
{
FIXME
(
"(%p) allocation of CubeTexture failed
\n
"
,
This
);
FIXME
(
"(%p) allocation of CubeTexture failed
\n
"
,
This
);
*
ppCubeTexture
=
NULL
;
*
ppCubeTexture
=
NULL
;
return
D3DERR_OUTOFVIDEOMEMORY
;
return
D3DERR_OUTOFVIDEOMEMORY
;
}
}
object
->
lpVtbl
=
&
Direct3DCubeTexture9_Vtbl
;
object
->
lpVtbl
=
&
Direct3DCubeTexture9_Vtbl
;
object
->
ref
=
1
;
object
->
ref
=
1
;
hr
=
IWineD3DDevice_CreateCubeTexture
(
This
->
WineD3DDevice
,
EdgeLength
,
Levels
,
Usage
,
hr
=
IWineD3DDevice_CreateCubeTexture
(
This
->
WineD3DDevice
,
EdgeLength
,
Levels
,
Usage
,
Format
,
Pool
,
&
(
object
->
wineD3DCubeTexture
),
pSharedHandle
,
(
IUnknown
*
)
object
,
Format
,
Pool
,
&
object
->
wineD3DCubeTexture
,
pSharedHandle
,
(
IUnknown
*
)
object
,
D3D9CB_CreateSurface
);
D3D9CB_CreateSurface
);
if
(
hr
!=
D3D_OK
)
{
if
(
hr
!=
D3D_OK
){
/* free up object */
/* free up object */
FIXME
(
"(%p) call to IWineD3DDevice_CreateCubeTexture failed
\n
"
,
This
);
FIXME
(
"(%p) call to IWineD3DDevice_CreateCubeTexture failed
\n
"
,
This
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
*
ppCubeTexture
=
NULL
;
*
ppCubeTexture
=
NULL
;
}
else
{
}
else
{
*
ppCubeTexture
=
(
LPDIRECT3DCUBETEXTURE9
)
object
;
*
ppCubeTexture
=
(
LPDIRECT3DCUBETEXTURE9
)
object
;
}
}
TRACE
(
"(%p) returning %p
\n
"
,
This
,
*
ppCubeTexture
);
return
hr
;
return
hr
;
}
}
dlls/d3d9/indexbuffer.c
View file @
8435f6f0
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DIndexBuffer9 IUnknown parts follow: */
/* IDirect3DIndexBuffer9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_QueryInterface
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_QueryInterface
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
...
@@ -31,7 +31,7 @@ HRESULT WINAPI IDirect3DIndexBuffer9Impl_QueryInterface(LPDIRECT3DINDEXBUFFER9 i
...
@@ -31,7 +31,7 @@ HRESULT WINAPI IDirect3DIndexBuffer9Impl_QueryInterface(LPDIRECT3DINDEXBUFFER9 i
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DIndexBuffer9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DIndexBuffer9
))
{
I
Direct3DIndexBuffer9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -65,58 +65,68 @@ ULONG WINAPI IDirect3DIndexBuffer9Impl_Release(LPDIRECT3DINDEXBUFFER9 iface) {
...
@@ -65,58 +65,68 @@ ULONG WINAPI IDirect3DIndexBuffer9Impl_Release(LPDIRECT3DINDEXBUFFER9 iface) {
/* IDirect3DIndexBuffer9 IDirect3DResource9 Interface follow: */
/* IDirect3DIndexBuffer9 IDirect3DResource9 Interface follow: */
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_GetDevice
(
LPDIRECT3DINDEXBUFFER9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_GetDevice
(
LPDIRECT3DINDEXBUFFER9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
}
}
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_SetPrivateData
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_SetPrivateData
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_SetPrivateData
(
This
->
wineD3DIndexBuffer
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DIndexBuffer_SetPrivateData
(
This
->
wineD3DIndexBuffer
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_GetPrivateData
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_GetPrivateData
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_GetPrivateData
(
This
->
wineD3DIndexBuffer
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DIndexBuffer_GetPrivateData
(
This
->
wineD3DIndexBuffer
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_FreePrivateData
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_FreePrivateData
(
LPDIRECT3DINDEXBUFFER9
iface
,
REFGUID
refguid
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_FreePrivateData
(
This
->
wineD3DIndexBuffer
,
refguid
);
return
IWineD3DIndexBuffer_FreePrivateData
(
This
->
wineD3DIndexBuffer
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DIndexBuffer9Impl_SetPriority
(
LPDIRECT3DINDEXBUFFER9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DIndexBuffer9Impl_SetPriority
(
LPDIRECT3DINDEXBUFFER9
iface
,
DWORD
PriorityNew
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_SetPriority
(
This
->
wineD3DIndexBuffer
,
PriorityNew
);
return
IWineD3DIndexBuffer_SetPriority
(
This
->
wineD3DIndexBuffer
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DIndexBuffer9Impl_GetPriority
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
DWORD
WINAPI
IDirect3DIndexBuffer9Impl_GetPriority
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_GetPriority
(
This
->
wineD3DIndexBuffer
);
return
IWineD3DIndexBuffer_GetPriority
(
This
->
wineD3DIndexBuffer
);
}
}
void
WINAPI
IDirect3DIndexBuffer9Impl_PreLoad
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
void
WINAPI
IDirect3DIndexBuffer9Impl_PreLoad
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IWineD3DIndexBuffer_PreLoad
(
This
->
wineD3DIndexBuffer
);
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
;
return
IWineD3DIndexBuffer_PreLoad
(
This
->
wineD3DIndexBuffer
)
;
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DIndexBuffer9Impl_GetType
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DIndexBuffer9Impl_GetType
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_GetType
(
This
->
wineD3DIndexBuffer
);
return
IWineD3DIndexBuffer_GetType
(
This
->
wineD3DIndexBuffer
);
}
}
/* IDirect3DIndexBuffer9 Interface follow: */
/* IDirect3DIndexBuffer9 Interface follow: */
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_Lock
(
LPDIRECT3DINDEXBUFFER9
iface
,
UINT
OffsetToLock
,
UINT
SizeToLock
,
void
**
ppbData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_Lock
(
LPDIRECT3DINDEXBUFFER9
iface
,
UINT
OffsetToLock
,
UINT
SizeToLock
,
void
**
ppbData
,
DWORD
Flags
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_Lock
(
This
->
wineD3DIndexBuffer
,
OffsetToLock
,
SizeToLock
,
(
BYTE
**
)
ppbData
,
Flags
);
return
IWineD3DIndexBuffer_Lock
(
This
->
wineD3DIndexBuffer
,
OffsetToLock
,
SizeToLock
,
(
BYTE
**
)
ppbData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_Unlock
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_Unlock
(
LPDIRECT3DINDEXBUFFER9
iface
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_Unlock
(
This
->
wineD3DIndexBuffer
);
return
IWineD3DIndexBuffer_Unlock
(
This
->
wineD3DIndexBuffer
);
}
}
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_GetDesc
(
LPDIRECT3DINDEXBUFFER9
iface
,
D3DINDEXBUFFER_DESC
*
pDesc
)
{
HRESULT
WINAPI
IDirect3DIndexBuffer9Impl_GetDesc
(
LPDIRECT3DINDEXBUFFER9
iface
,
D3DINDEXBUFFER_DESC
*
pDesc
)
{
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
IDirect3DIndexBuffer9Impl
*
This
=
(
IDirect3DIndexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DIndexBuffer_GetDesc
(
This
->
wineD3DIndexBuffer
,
pDesc
);
return
IWineD3DIndexBuffer_GetDesc
(
This
->
wineD3DIndexBuffer
,
pDesc
);
}
}
...
@@ -142,15 +152,16 @@ IDirect3DIndexBuffer9Vtbl Direct3DIndexBuffer9_Vtbl =
...
@@ -142,15 +152,16 @@ IDirect3DIndexBuffer9Vtbl Direct3DIndexBuffer9_Vtbl =
/* IDirect3DDevice9 IDirect3DIndexBuffer9 Methods follow: */
/* IDirect3DDevice9 IDirect3DIndexBuffer9 Methods follow: */
HRESULT
WINAPI
IDirect3DDevice9Impl_CreateIndexBuffer
(
LPDIRECT3DDEVICE9
iface
,
HRESULT
WINAPI
IDirect3DDevice9Impl_CreateIndexBuffer
(
LPDIRECT3DDEVICE9
iface
,
UINT
Length
,
DWORD
Usage
,
D3DFORMAT
Format
,
D3DPOOL
Pool
,
UINT
Length
,
DWORD
Usage
,
D3DFORMAT
Format
,
D3DPOOL
Pool
,
IDirect3DIndexBuffer9
**
ppIndexBuffer
,
HANDLE
*
pSharedHandle
)
{
IDirect3DIndexBuffer9
**
ppIndexBuffer
,
HANDLE
*
pSharedHandle
)
{
IDirect3DIndexBuffer9Impl
*
object
;
IDirect3DIndexBuffer9Impl
*
object
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
HRESULT
hrc
=
D3D_OK
;
HRESULT
hrc
=
D3D_OK
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* Allocate the storage for the device */
/* Allocate the storage for the device */
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
IDirect3DIndexBuffer9Impl
));
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
if
(
NULL
==
object
)
{
if
(
NULL
==
object
)
{
FIXME
(
"Allocation of memory failed
\n
"
);
FIXME
(
"Allocation of memory failed
\n
"
);
*
ppIndexBuffer
=
NULL
;
*
ppIndexBuffer
=
NULL
;
...
@@ -159,7 +170,8 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateIndexBuffer(LPDIRECT3DDEVICE9 iface,
...
@@ -159,7 +170,8 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateIndexBuffer(LPDIRECT3DDEVICE9 iface,
object
->
lpVtbl
=
&
Direct3DIndexBuffer9_Vtbl
;
object
->
lpVtbl
=
&
Direct3DIndexBuffer9_Vtbl
;
object
->
ref
=
1
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateIndexBuffer
(
This
->
WineD3DDevice
,
Length
,
Usage
,
Format
,
Pool
,
&
(
object
->
wineD3DIndexBuffer
),
pSharedHandle
,
(
IUnknown
*
)
object
);
TRACE
(
"Calling wined3d create index buffer
\n
"
);
hrc
=
IWineD3DDevice_CreateIndexBuffer
(
This
->
WineD3DDevice
,
Length
,
Usage
,
Format
,
Pool
,
&
object
->
wineD3DIndexBuffer
,
pSharedHandle
,
(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
)
{
if
(
hrc
!=
D3D_OK
)
{
/* free up object */
/* free up object */
FIXME
(
"(%p) call to IWineD3DDevice_CreateIndexBuffer failed
\n
"
,
This
);
FIXME
(
"(%p) call to IWineD3DDevice_CreateIndexBuffer failed
\n
"
,
This
);
...
...
dlls/d3d9/resource.c
View file @
8435f6f0
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DResource9 IUnknown parts follow: */
/* IDirect3DResource9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DResource9Impl_QueryInterface
(
LPDIRECT3DRESOURCE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DResource9Impl_QueryInterface
(
LPDIRECT3DRESOURCE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
...
@@ -65,6 +65,9 @@ ULONG WINAPI IDirect3DResource9Impl_Release(LPDIRECT3DRESOURCE9 iface) {
...
@@ -65,6 +65,9 @@ ULONG WINAPI IDirect3DResource9Impl_Release(LPDIRECT3DRESOURCE9 iface) {
HRESULT
WINAPI
IDirect3DResource9Impl_GetDevice
(
LPDIRECT3DRESOURCE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
HRESULT
WINAPI
IDirect3DResource9Impl_GetDevice
(
LPDIRECT3DRESOURCE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IWineD3DDevice
*
myDevice
=
NULL
;
IWineD3DDevice
*
myDevice
=
NULL
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
IWineD3DResource_GetDevice
(
This
->
wineD3DResource
,
&
myDevice
);
IWineD3DResource_GetDevice
(
This
->
wineD3DResource
,
&
myDevice
);
IWineD3DDevice_GetParent
(
myDevice
,
(
IUnknown
**
)
ppDevice
);
IWineD3DDevice_GetParent
(
myDevice
,
(
IUnknown
**
)
ppDevice
);
IWineD3DDevice_Release
(
myDevice
);
IWineD3DDevice_Release
(
myDevice
);
...
@@ -73,37 +76,44 @@ HRESULT WINAPI IDirect3DResource9Impl_GetDevice(LPDIRECT3DRESOURCE9 iface, IDire
...
@@ -73,37 +76,44 @@ HRESULT WINAPI IDirect3DResource9Impl_GetDevice(LPDIRECT3DRESOURCE9 iface, IDire
HRESULT
WINAPI
IDirect3DResource9Impl_SetPrivateData
(
LPDIRECT3DRESOURCE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DResource9Impl_SetPrivateData
(
LPDIRECT3DRESOURCE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DResource_SetPrivateData
(
This
->
wineD3DResource
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DResource_SetPrivateData
(
This
->
wineD3DResource
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DResource9Impl_GetPrivateData
(
LPDIRECT3DRESOURCE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DResource9Impl_GetPrivateData
(
LPDIRECT3DRESOURCE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DResource_GetPrivateData
(
This
->
wineD3DResource
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DResource_GetPrivateData
(
This
->
wineD3DResource
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DResource9Impl_FreePrivateData
(
LPDIRECT3DRESOURCE9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DResource9Impl_FreePrivateData
(
LPDIRECT3DRESOURCE9
iface
,
REFGUID
refguid
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DResource_FreePrivateData
(
This
->
wineD3DResource
,
refguid
);
return
IWineD3DResource_FreePrivateData
(
This
->
wineD3DResource
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DResource9Impl_SetPriority
(
LPDIRECT3DRESOURCE9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DResource9Impl_SetPriority
(
LPDIRECT3DRESOURCE9
iface
,
DWORD
PriorityNew
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DResource_SetPriority
(
This
->
wineD3DResource
,
PriorityNew
);
return
IWineD3DResource_SetPriority
(
This
->
wineD3DResource
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DResource9Impl_GetPriority
(
LPDIRECT3DRESOURCE9
iface
)
{
DWORD
WINAPI
IDirect3DResource9Impl_GetPriority
(
LPDIRECT3DRESOURCE9
iface
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DResource_GetPriority
(
This
->
wineD3DResource
);
return
IWineD3DResource_GetPriority
(
This
->
wineD3DResource
);
}
}
void
WINAPI
IDirect3DResource9Impl_PreLoad
(
LPDIRECT3DRESOURCE9
iface
)
{
void
WINAPI
IDirect3DResource9Impl_PreLoad
(
LPDIRECT3DRESOURCE9
iface
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
IWineD3DResource_PreLoad
(
This
->
wineD3DResource
);
IWineD3DResource_PreLoad
(
This
->
wineD3DResource
);
return
;
return
;
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DResource9Impl_GetType
(
LPDIRECT3DRESOURCE9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DResource9Impl_GetType
(
LPDIRECT3DRESOURCE9
iface
)
{
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
IDirect3DResource9Impl
*
This
=
(
IDirect3DResource9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DResource_GetType
(
This
->
wineD3DResource
);
return
IWineD3DResource_GetType
(
This
->
wineD3DResource
);
}
}
...
...
dlls/d3d9/surface.c
View file @
8435f6f0
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
_surface
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DSurface9 IUnknown parts follow: */
/* IDirect3DSurface9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DSurface9Impl_QueryInterface
(
LPDIRECT3DSURFACE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_QueryInterface
(
LPDIRECT3DSURFACE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
...
@@ -31,7 +31,7 @@ HRESULT WINAPI IDirect3DSurface9Impl_QueryInterface(LPDIRECT3DSURFACE9 iface, RE
...
@@ -31,7 +31,7 @@ HRESULT WINAPI IDirect3DSurface9Impl_QueryInterface(LPDIRECT3DSURFACE9 iface, RE
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DSurface9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DSurface9
))
{
I
Direct3DSurface9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -70,37 +70,44 @@ HRESULT WINAPI IDirect3DSurface9Impl_GetDevice(LPDIRECT3DSURFACE9 iface, IDirect
...
@@ -70,37 +70,44 @@ HRESULT WINAPI IDirect3DSurface9Impl_GetDevice(LPDIRECT3DSURFACE9 iface, IDirect
HRESULT
WINAPI
IDirect3DSurface9Impl_SetPrivateData
(
LPDIRECT3DSURFACE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_SetPrivateData
(
LPDIRECT3DSURFACE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_SetPrivateData
(
This
->
wineD3DSurface
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DSurface_SetPrivateData
(
This
->
wineD3DSurface
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DSurface9Impl_GetPrivateData
(
LPDIRECT3DSURFACE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_GetPrivateData
(
LPDIRECT3DSURFACE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_GetPrivateData
(
This
->
wineD3DSurface
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DSurface_GetPrivateData
(
This
->
wineD3DSurface
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DSurface9Impl_FreePrivateData
(
LPDIRECT3DSURFACE9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_FreePrivateData
(
LPDIRECT3DSURFACE9
iface
,
REFGUID
refguid
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_FreePrivateData
(
This
->
wineD3DSurface
,
refguid
);
return
IWineD3DSurface_FreePrivateData
(
This
->
wineD3DSurface
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DSurface9Impl_SetPriority
(
LPDIRECT3DSURFACE9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DSurface9Impl_SetPriority
(
LPDIRECT3DSURFACE9
iface
,
DWORD
PriorityNew
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_SetPriority
(
This
->
wineD3DSurface
,
PriorityNew
);
return
IWineD3DSurface_SetPriority
(
This
->
wineD3DSurface
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DSurface9Impl_GetPriority
(
LPDIRECT3DSURFACE9
iface
)
{
DWORD
WINAPI
IDirect3DSurface9Impl_GetPriority
(
LPDIRECT3DSURFACE9
iface
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_GetPriority
(
This
->
wineD3DSurface
);
return
IWineD3DSurface_GetPriority
(
This
->
wineD3DSurface
);
}
}
void
WINAPI
IDirect3DSurface9Impl_PreLoad
(
LPDIRECT3DSURFACE9
iface
)
{
void
WINAPI
IDirect3DSurface9Impl_PreLoad
(
LPDIRECT3DSURFACE9
iface
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
IWineD3DSurface_PreLoad
(
This
->
wineD3DSurface
);
IWineD3DSurface_PreLoad
(
This
->
wineD3DSurface
);
return
;
return
;
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DSurface9Impl_GetType
(
LPDIRECT3DSURFACE9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DSurface9Impl_GetType
(
LPDIRECT3DSURFACE9
iface
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_GetType
(
This
->
wineD3DSurface
);
return
IWineD3DSurface_GetType
(
This
->
wineD3DSurface
);
}
}
...
@@ -108,13 +115,12 @@ D3DRESOURCETYPE WINAPI IDirect3DSurface9Impl_GetType(LPDIRECT3DSURFACE9 iface) {
...
@@ -108,13 +115,12 @@ D3DRESOURCETYPE WINAPI IDirect3DSurface9Impl_GetType(LPDIRECT3DSURFACE9 iface) {
HRESULT
WINAPI
IDirect3DSurface9Impl_GetContainer
(
LPDIRECT3DSURFACE9
iface
,
REFIID
riid
,
void
**
ppContainer
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_GetContainer
(
LPDIRECT3DSURFACE9
iface
,
REFIID
riid
,
void
**
ppContainer
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
HRESULT
res
;
HRESULT
res
;
/* The container returned from IWineD3DSurface_GetContainer is either a IWineD3DDevice,
one of the subclasses of IWineD3DBaseTexture or a IWineD3DSwapChain */
IUnknown
*
IWineContainer
=
NULL
;
IUnknown
*
IWineContainer
=
NULL
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* The container returned from IWineD3DSurface_GetContainer is either a IWineD3DDevice,
one of the subclasses of IWineD3DBaseTexture or a IWineD3DSwapChain */
/* Get the IUnknown container. */
/* Get the IUnknown container. */
res
=
IWineD3DSurface_GetContainer
(
This
->
wineD3DSurface
,
&
IID_IUnknown
,
(
void
**
)
&
IWineContainer
);
res
=
IWineD3DSurface_GetContainer
(
This
->
wineD3DSurface
,
&
IID_IUnknown
,
(
void
**
)
&
IWineContainer
);
if
(
res
==
D3D_OK
&&
IWineContainer
!=
NULL
)
{
if
(
res
==
D3D_OK
&&
IWineContainer
!=
NULL
)
{
...
@@ -156,6 +162,7 @@ HRESULT WINAPI IDirect3DSurface9Impl_GetDesc(LPDIRECT3DSURFACE9 iface, D3DSURFAC
...
@@ -156,6 +162,7 @@ HRESULT WINAPI IDirect3DSurface9Impl_GetDesc(LPDIRECT3DSURFACE9 iface, D3DSURFAC
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
WINED3DSURFACE_DESC
wined3ddesc
;
WINED3DSURFACE_DESC
wined3ddesc
;
UINT
tmpInt
=
-
1
;
UINT
tmpInt
=
-
1
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
...
@@ -173,21 +180,26 @@ HRESULT WINAPI IDirect3DSurface9Impl_GetDesc(LPDIRECT3DSURFACE9 iface, D3DSURFAC
...
@@ -173,21 +180,26 @@ HRESULT WINAPI IDirect3DSurface9Impl_GetDesc(LPDIRECT3DSURFACE9 iface, D3DSURFAC
HRESULT
WINAPI
IDirect3DSurface9Impl_LockRect
(
LPDIRECT3DSURFACE9
iface
,
D3DLOCKED_RECT
*
pLockedRect
,
CONST
RECT
*
pRect
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_LockRect
(
LPDIRECT3DSURFACE9
iface
,
D3DLOCKED_RECT
*
pLockedRect
,
CONST
RECT
*
pRect
,
DWORD
Flags
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
TRACE
(
"(%p) calling IWineD3DSurface_LockRect %p %p %p %ld
\n
"
,
This
,
This
->
wineD3DSurface
,
pLockedRect
,
pRect
,
Flags
);
return
IWineD3DSurface_LockRect
(
This
->
wineD3DSurface
,
pLockedRect
,
pRect
,
Flags
);
return
IWineD3DSurface_LockRect
(
This
->
wineD3DSurface
,
pLockedRect
,
pRect
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DSurface9Impl_UnlockRect
(
LPDIRECT3DSURFACE9
iface
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_UnlockRect
(
LPDIRECT3DSURFACE9
iface
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_UnlockRect
(
This
->
wineD3DSurface
);
return
IWineD3DSurface_UnlockRect
(
This
->
wineD3DSurface
);
}
}
HRESULT
WINAPI
IDirect3DSurface9Impl_GetDC
(
LPDIRECT3DSURFACE9
iface
,
HDC
*
phdc
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_GetDC
(
LPDIRECT3DSURFACE9
iface
,
HDC
*
phdc
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_GetDC
(
This
->
wineD3DSurface
,
phdc
);
return
IWineD3DSurface_GetDC
(
This
->
wineD3DSurface
,
phdc
);
}
}
HRESULT
WINAPI
IDirect3DSurface9Impl_ReleaseDC
(
LPDIRECT3DSURFACE9
iface
,
HDC
hdc
)
{
HRESULT
WINAPI
IDirect3DSurface9Impl_ReleaseDC
(
LPDIRECT3DSURFACE9
iface
,
HDC
hdc
)
{
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
IDirect3DSurface9Impl
*
This
=
(
IDirect3DSurface9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DSurface_ReleaseDC
(
This
->
wineD3DSurface
,
hdc
);
return
IWineD3DSurface_ReleaseDC
(
This
->
wineD3DSurface
,
hdc
);
}
}
...
...
dlls/d3d9/texture.c
View file @
8435f6f0
...
@@ -2,7 +2,8 @@
...
@@ -2,7 +2,8 @@
* IDirect3DTexture9 implementation
* IDirect3DTexture9 implementation
*
*
* Copyright 2002-2005 Jason Edmeades
* Copyright 2002-2005 Jason Edmeades
* Raphael Junqueira
* Copyright 2002-2005 Raphael Junqueira
* Copyright 2005 Oliver Stieber
*
*
* This library is free software; you can redistribute it and/or
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* modify it under the terms of the GNU Lesser General Public
...
@@ -22,7 +23,7 @@
...
@@ -22,7 +23,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DTexture9 IUnknown parts follow: */
/* IDirect3DTexture9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DTexture9Impl_QueryInterface
(
LPDIRECT3DTEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DTexture9Impl_QueryInterface
(
LPDIRECT3DTEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
...
@@ -32,7 +33,7 @@ HRESULT WINAPI IDirect3DTexture9Impl_QueryInterface(LPDIRECT3DTEXTURE9 iface, RE
...
@@ -32,7 +33,7 @@ HRESULT WINAPI IDirect3DTexture9Impl_QueryInterface(LPDIRECT3DTEXTURE9 iface, RE
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DTexture9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DTexture9
))
{
I
Direct3DTexture9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -71,17 +72,17 @@ HRESULT WINAPI IDirect3DTexture9Impl_GetDevice(LPDIRECT3DTEXTURE9 iface, IDirect
...
@@ -71,17 +72,17 @@ HRESULT WINAPI IDirect3DTexture9Impl_GetDevice(LPDIRECT3DTEXTURE9 iface, IDirect
HRESULT
WINAPI
IDirect3DTexture9Impl_SetPrivateData
(
LPDIRECT3DTEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DTexture9Impl_SetPrivateData
(
LPDIRECT3DTEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
return
IWineD3DTexture_SetPrivateData
(
This
->
wineD3DTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DTexture_SetPrivateData
(
This
->
wineD3DTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DTexture9Impl_GetPrivateData
(
LPDIRECT3DTEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DTexture9Impl_GetPrivateData
(
LPDIRECT3DTEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
return
IWineD3DTexture_GetPrivateData
(
This
->
wineD3DTexture
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DTexture_GetPrivateData
(
This
->
wineD3DTexture
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DTexture9Impl_FreePrivateData
(
LPDIRECT3DTEXTURE9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DTexture9Impl_FreePrivateData
(
LPDIRECT3DTEXTURE9
iface
,
REFGUID
refguid
)
{
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
return
IWineD3DTexture_FreePrivateData
(
This
->
wineD3DTexture
,
refguid
);
return
IWineD3DTexture_FreePrivateData
(
This
->
wineD3DTexture
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DTexture9Impl_SetPriority
(
LPDIRECT3DTEXTURE9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DTexture9Impl_SetPriority
(
LPDIRECT3DTEXTURE9
iface
,
DWORD
PriorityNew
)
{
...
@@ -147,7 +148,7 @@ HRESULT WINAPI IDirect3DTexture9Impl_GetLevelDesc(LPDIRECT3DTEXTURE9 iface, UINT
...
@@ -147,7 +148,7 @@ HRESULT WINAPI IDirect3DTexture9Impl_GetLevelDesc(LPDIRECT3DTEXTURE9 iface, UINT
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
wined3ddesc
.
Usage
=
&
pDesc
->
Usage
;
wined3ddesc
.
Usage
=
&
pDesc
->
Usage
;
wined3ddesc
.
Pool
=
&
pDesc
->
Pool
;
wined3ddesc
.
Pool
=
&
pDesc
->
Pool
;
wined3ddesc
.
Size
=
&
tmpInt
;
wined3ddesc
.
Size
=
&
tmpInt
;
/* required for d3d8 */
wined3ddesc
.
MultiSampleType
=
&
pDesc
->
MultiSampleType
;
wined3ddesc
.
MultiSampleType
=
&
pDesc
->
MultiSampleType
;
wined3ddesc
.
MultiSampleQuality
=
&
pDesc
->
MultiSampleQuality
;
wined3ddesc
.
MultiSampleQuality
=
&
pDesc
->
MultiSampleQuality
;
wined3ddesc
.
Width
=
&
pDesc
->
Width
;
wined3ddesc
.
Width
=
&
pDesc
->
Width
;
...
@@ -169,7 +170,7 @@ HRESULT WINAPI IDirect3DTexture9Impl_GetSurfaceLevel(LPDIRECT3DTEXTURE9 iface, U
...
@@ -169,7 +170,7 @@ HRESULT WINAPI IDirect3DTexture9Impl_GetSurfaceLevel(LPDIRECT3DTEXTURE9 iface, U
return
hrc
;
return
hrc
;
}
}
HRESULT
WINAPI
IDirect3DTexture9Impl_LockRect
(
LPDIRECT3DTEXTURE9
iface
,
UINT
Level
,
D3DLOCKED_RECT
*
pLockedRect
,
CONST
RECT
*
pRect
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DTexture9Impl_LockRect
(
LPDIRECT3DTEXTURE9
iface
,
UINT
Level
,
D3DLOCKED_RECT
*
pLockedRect
,
CONST
RECT
*
pRect
,
DWORD
Flags
)
{
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
IDirect3DTexture9Impl
*
This
=
(
IDirect3DTexture9Impl
*
)
iface
;
return
IWineD3DTexture_LockRect
(
This
->
wineD3DTexture
,
Level
,
pLockedRect
,
pRect
,
Flags
);
return
IWineD3DTexture_LockRect
(
This
->
wineD3DTexture
,
Level
,
pLockedRect
,
pRect
,
Flags
);
}
}
...
@@ -184,7 +185,6 @@ HRESULT WINAPI IDirect3DTexture9Impl_AddDirtyRect(LPDIRECT3DTEXTURE9 iface, CONS
...
@@ -184,7 +185,6 @@ HRESULT WINAPI IDirect3DTexture9Impl_AddDirtyRect(LPDIRECT3DTEXTURE9 iface, CONS
return
IWineD3DTexture_AddDirtyRect
(
This
->
wineD3DTexture
,
pDirtyRect
);
return
IWineD3DTexture_AddDirtyRect
(
This
->
wineD3DTexture
,
pDirtyRect
);
}
}
IDirect3DTexture9Vtbl
Direct3DTexture9_Vtbl
=
IDirect3DTexture9Vtbl
Direct3DTexture9_Vtbl
=
{
{
IDirect3DTexture9Impl_QueryInterface
,
IDirect3DTexture9Impl_QueryInterface
,
...
@@ -198,6 +198,7 @@ IDirect3DTexture9Vtbl Direct3DTexture9_Vtbl =
...
@@ -198,6 +198,7 @@ IDirect3DTexture9Vtbl Direct3DTexture9_Vtbl =
IDirect3DTexture9Impl_GetPriority
,
IDirect3DTexture9Impl_GetPriority
,
IDirect3DTexture9Impl_PreLoad
,
IDirect3DTexture9Impl_PreLoad
,
IDirect3DTexture9Impl_GetType
,
IDirect3DTexture9Impl_GetType
,
IDirect3DTexture9Impl_SetLOD
,
IDirect3DTexture9Impl_SetLOD
,
IDirect3DTexture9Impl_GetLOD
,
IDirect3DTexture9Impl_GetLOD
,
IDirect3DTexture9Impl_GetLevelCount
,
IDirect3DTexture9Impl_GetLevelCount
,
...
@@ -219,8 +220,11 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateTexture(LPDIRECT3DDEVICE9 iface, UIN
...
@@ -219,8 +220,11 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateTexture(LPDIRECT3DDEVICE9 iface, UIN
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
HRESULT
hrc
=
D3D_OK
;
HRESULT
hrc
=
D3D_OK
;
TRACE
(
"(%p) : W(%d) H(%d), Lvl(%d) d(%ld), Fmt(%u), Pool(%d)
\n
"
,
This
,
Width
,
Height
,
Levels
,
Usage
,
Format
,
Pool
);
/* Allocate the storage for the device */
/* Allocate the storage for the device */
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
IDirect3DTexture9Impl
));
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
IDirect3DTexture9Impl
));
if
(
NULL
==
object
)
{
if
(
NULL
==
object
)
{
FIXME
(
"Allocation of memory failed
\n
"
);
FIXME
(
"Allocation of memory failed
\n
"
);
*
ppTexture
=
NULL
;
*
ppTexture
=
NULL
;
...
@@ -230,15 +234,17 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateTexture(LPDIRECT3DDEVICE9 iface, UIN
...
@@ -230,15 +234,17 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateTexture(LPDIRECT3DDEVICE9 iface, UIN
object
->
lpVtbl
=
&
Direct3DTexture9_Vtbl
;
object
->
lpVtbl
=
&
Direct3DTexture9_Vtbl
;
object
->
ref
=
1
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Levels
,
Usage
,
hrc
=
IWineD3DDevice_CreateTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Levels
,
Usage
,
Format
,
Pool
,
&
(
object
->
wineD3DTexture
)
,
pSharedHandle
,
(
IUnknown
*
)
object
,
D3D9CB_CreateSurface
);
Format
,
Pool
,
&
object
->
wineD3DTexture
,
pSharedHandle
,
(
IUnknown
*
)
object
,
D3D9CB_CreateSurface
);
if
(
FAILED
(
hrc
))
{
if
(
FAILED
(
hrc
))
{
/* free up object */
/* free up object */
FIXME
(
"(%p) call to IWineD3DDevice_CreateTexture failed
\n
"
,
This
);
FIXME
(
"(%p) call to IWineD3DDevice_CreateTexture failed
\n
"
,
This
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
*
ppTexture
=
NULL
;
*
ppTexture
=
NULL
;
}
else
{
}
else
{
*
ppTexture
=
(
LPDIRECT3DTEXTURE9
)
object
;
*
ppTexture
=
(
LPDIRECT3DTEXTURE9
)
object
;
}
}
return
hrc
;
TRACE
(
"(%p) Created Texture %p, %p
\n
"
,
This
,
object
,
object
->
wineD3DTexture
);
return
hrc
;
}
}
dlls/d3d9/vertexbuffer.c
View file @
8435f6f0
...
@@ -2,7 +2,8 @@
...
@@ -2,7 +2,8 @@
* IDirect3DVertexBuffer9 implementation
* IDirect3DVertexBuffer9 implementation
*
*
* Copyright 2002-2004 Jason Edmeades
* Copyright 2002-2004 Jason Edmeades
* Raphael Junqueira
* Copyright 2002-2004 Raphael Junqueira
* Copyright 2005 Oliver Stieber
*
*
* This library is free software; you can redistribute it and/or
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* modify it under the terms of the GNU Lesser General Public
...
@@ -22,7 +23,7 @@
...
@@ -22,7 +23,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DVertexBuffer9 IUnknown parts follow: */
/* IDirect3DVertexBuffer9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_QueryInterface
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_QueryInterface
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
...
@@ -31,7 +32,7 @@ HRESULT WINAPI IDirect3DVertexBuffer9Impl_QueryInterface(LPDIRECT3DVERTEXBUFFER9
...
@@ -31,7 +32,7 @@ HRESULT WINAPI IDirect3DVertexBuffer9Impl_QueryInterface(LPDIRECT3DVERTEXBUFFER9
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DVertexBuffer9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DVertexBuffer9
))
{
I
Direct3DVertexBuffer9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -65,58 +66,69 @@ ULONG WINAPI IDirect3DVertexBuffer9Impl_Release(LPDIRECT3DVERTEXBUFFER9 iface) {
...
@@ -65,58 +66,69 @@ ULONG WINAPI IDirect3DVertexBuffer9Impl_Release(LPDIRECT3DVERTEXBUFFER9 iface) {
/* IDirect3DVertexBuffer9 IDirect3DResource9 Interface follow: */
/* IDirect3DVertexBuffer9 IDirect3DResource9 Interface follow: */
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_GetDevice
(
LPDIRECT3DVERTEXBUFFER9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_GetDevice
(
LPDIRECT3DVERTEXBUFFER9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
}
}
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_SetPrivateData
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_SetPrivateData
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_SetPrivateData
(
This
->
wineD3DVertexBuffer
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DVertexBuffer_SetPrivateData
(
This
->
wineD3DVertexBuffer
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_GetPrivateData
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_GetPrivateData
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_GetPrivateData
(
This
->
wineD3DVertexBuffer
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DVertexBuffer_GetPrivateData
(
This
->
wineD3DVertexBuffer
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_FreePrivateData
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_FreePrivateData
(
LPDIRECT3DVERTEXBUFFER9
iface
,
REFGUID
refguid
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_FreePrivateData
(
This
->
wineD3DVertexBuffer
,
refguid
);
return
IWineD3DVertexBuffer_FreePrivateData
(
This
->
wineD3DVertexBuffer
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DVertexBuffer9Impl_SetPriority
(
LPDIRECT3DVERTEXBUFFER9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DVertexBuffer9Impl_SetPriority
(
LPDIRECT3DVERTEXBUFFER9
iface
,
DWORD
PriorityNew
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_SetPriority
(
This
->
wineD3DVertexBuffer
,
PriorityNew
);
return
IWineD3DVertexBuffer_SetPriority
(
This
->
wineD3DVertexBuffer
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DVertexBuffer9Impl_GetPriority
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
DWORD
WINAPI
IDirect3DVertexBuffer9Impl_GetPriority
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_GetPriority
(
This
->
wineD3DVertexBuffer
);
return
IWineD3DVertexBuffer_GetPriority
(
This
->
wineD3DVertexBuffer
);
}
}
void
WINAPI
IDirect3DVertexBuffer9Impl_PreLoad
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
void
WINAPI
IDirect3DVertexBuffer9Impl_PreLoad
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
IWineD3DVertexBuffer_PreLoad
(
This
->
wineD3DVertexBuffer
);
IWineD3DVertexBuffer_PreLoad
(
This
->
wineD3DVertexBuffer
);
return
;
return
;
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DVertexBuffer9Impl_GetType
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DVertexBuffer9Impl_GetType
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_GetType
(
This
->
wineD3DVertexBuffer
);
return
IWineD3DVertexBuffer_GetType
(
This
->
wineD3DVertexBuffer
);
}
}
/* IDirect3DVertexBuffer9 Interface follow: */
/* IDirect3DVertexBuffer9 Interface follow: */
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_Lock
(
LPDIRECT3DVERTEXBUFFER9
iface
,
UINT
OffsetToLock
,
UINT
SizeToLock
,
void
**
ppbData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_Lock
(
LPDIRECT3DVERTEXBUFFER9
iface
,
UINT
OffsetToLock
,
UINT
SizeToLock
,
void
**
ppbData
,
DWORD
Flags
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_Lock
(
This
->
wineD3DVertexBuffer
,
OffsetToLock
,
SizeToLock
,
(
BYTE
**
)
ppbData
,
Flags
);
return
IWineD3DVertexBuffer_Lock
(
This
->
wineD3DVertexBuffer
,
OffsetToLock
,
SizeToLock
,
(
BYTE
**
)
ppbData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_Unlock
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_Unlock
(
LPDIRECT3DVERTEXBUFFER9
iface
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_Unlock
(
This
->
wineD3DVertexBuffer
);
return
IWineD3DVertexBuffer_Unlock
(
This
->
wineD3DVertexBuffer
);
}
}
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_GetDesc
(
LPDIRECT3DVERTEXBUFFER9
iface
,
D3DVERTEXBUFFER_DESC
*
pDesc
)
{
HRESULT
WINAPI
IDirect3DVertexBuffer9Impl_GetDesc
(
LPDIRECT3DVERTEXBUFFER9
iface
,
D3DVERTEXBUFFER_DESC
*
pDesc
)
{
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
IDirect3DVertexBuffer9Impl
*
This
=
(
IDirect3DVertexBuffer9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVertexBuffer_GetDesc
(
This
->
wineD3DVertexBuffer
,
pDesc
);
return
IWineD3DVertexBuffer_GetDesc
(
This
->
wineD3DVertexBuffer
,
pDesc
);
}
}
...
@@ -141,8 +153,8 @@ IDirect3DVertexBuffer9Vtbl Direct3DVertexBuffer9_Vtbl =
...
@@ -141,8 +153,8 @@ IDirect3DVertexBuffer9Vtbl Direct3DVertexBuffer9_Vtbl =
/* IDirect3DDevice9 IDirect3DVertexBuffer9 Methods follow: */
/* IDirect3DDevice9 IDirect3DVertexBuffer9 Methods follow: */
HRESULT
WINAPI
IDirect3DDevice9Impl_CreateVertexBuffer
(
LPDIRECT3DDEVICE9
iface
,
HRESULT
WINAPI
IDirect3DDevice9Impl_CreateVertexBuffer
(
LPDIRECT3DDEVICE9
iface
,
UINT
Size
,
DWORD
Usage
,
DWORD
FVF
,
D3DPOOL
Pool
,
UINT
Size
,
DWORD
Usage
,
DWORD
FVF
,
D3DPOOL
Pool
,
IDirect3DVertexBuffer9
**
ppVertexBuffer
,
HANDLE
*
pSharedHandle
)
{
IDirect3DVertexBuffer9
**
ppVertexBuffer
,
HANDLE
*
pSharedHandle
)
{
IDirect3DVertexBuffer9Impl
*
object
;
IDirect3DVertexBuffer9Impl
*
object
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
...
...
dlls/d3d9/volume.c
View file @
8435f6f0
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DVolume9 IUnknown parts follow: */
/* IDirect3DVolume9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DVolume9Impl_QueryInterface
(
LPDIRECT3DVOLUME9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_QueryInterface
(
LPDIRECT3DVOLUME9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
...
@@ -30,7 +30,7 @@ HRESULT WINAPI IDirect3DVolume9Impl_QueryInterface(LPDIRECT3DVOLUME9 iface, REFI
...
@@ -30,7 +30,7 @@ HRESULT WINAPI IDirect3DVolume9Impl_QueryInterface(LPDIRECT3DVOLUME9 iface, REFI
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DVolume9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DVolume9
))
{
I
Direct3DVolume9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -74,24 +74,28 @@ HRESULT WINAPI IDirect3DVolume9Impl_GetDevice(LPDIRECT3DVOLUME9 iface, IDirect3D
...
@@ -74,24 +74,28 @@ HRESULT WINAPI IDirect3DVolume9Impl_GetDevice(LPDIRECT3DVOLUME9 iface, IDirect3D
HRESULT
WINAPI
IDirect3DVolume9Impl_SetPrivateData
(
LPDIRECT3DVOLUME9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_SetPrivateData
(
LPDIRECT3DVOLUME9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolume_SetPrivateData
(
This
->
wineD3DVolume
,
refguid
,
pData
,
SizeOfData
,
Flags
);
return
IWineD3DVolume_SetPrivateData
(
This
->
wineD3DVolume
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DVolume9Impl_GetPrivateData
(
LPDIRECT3DVOLUME9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_GetPrivateData
(
LPDIRECT3DVOLUME9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolume_GetPrivateData
(
This
->
wineD3DVolume
,
refguid
,
pData
,
pSizeOfData
);
return
IWineD3DVolume_GetPrivateData
(
This
->
wineD3DVolume
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DVolume9Impl_FreePrivateData
(
LPDIRECT3DVOLUME9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_FreePrivateData
(
LPDIRECT3DVOLUME9
iface
,
REFGUID
refguid
)
{
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolume_FreePrivateData
(
This
->
wineD3DVolume
,
refguid
);
return
IWineD3DVolume_FreePrivateData
(
This
->
wineD3DVolume
,
refguid
);
}
}
HRESULT
WINAPI
IDirect3DVolume9Impl_GetContainer
(
LPDIRECT3DVOLUME9
iface
,
REFIID
riid
,
void
**
ppContainer
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_GetContainer
(
LPDIRECT3DVOLUME9
iface
,
REFIID
riid
,
void
**
ppContainer
)
{
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
HRESULT
res
;
HRESULT
res
;
IUnknown
*
IWineContainer
=
NULL
;
IUnknown
*
IWineContainer
=
NULL
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
res
=
IWineD3DVolume_GetContainer
(
This
->
wineD3DVolume
,
riid
,
(
void
**
)
&
IWineContainer
);
res
=
IWineD3DVolume_GetContainer
(
This
->
wineD3DVolume
,
riid
,
(
void
**
)
&
IWineContainer
);
/* If this works, the only valid container is a child of resource (volumetexture) */
/* If this works, the only valid container is a child of resource (volumetexture) */
...
@@ -108,6 +112,8 @@ HRESULT WINAPI IDirect3DVolume9Impl_GetDesc(LPDIRECT3DVOLUME9 iface, D3DVOLUME_D
...
@@ -108,6 +112,8 @@ HRESULT WINAPI IDirect3DVolume9Impl_GetDesc(LPDIRECT3DVOLUME9 iface, D3DVOLUME_D
WINED3DVOLUME_DESC
wined3ddesc
;
WINED3DVOLUME_DESC
wined3ddesc
;
UINT
tmpInt
=
-
1
;
UINT
tmpInt
=
-
1
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
...
@@ -123,11 +129,13 @@ HRESULT WINAPI IDirect3DVolume9Impl_GetDesc(LPDIRECT3DVOLUME9 iface, D3DVOLUME_D
...
@@ -123,11 +129,13 @@ HRESULT WINAPI IDirect3DVolume9Impl_GetDesc(LPDIRECT3DVOLUME9 iface, D3DVOLUME_D
HRESULT
WINAPI
IDirect3DVolume9Impl_LockBox
(
LPDIRECT3DVOLUME9
iface
,
D3DLOCKED_BOX
*
pLockedVolume
,
CONST
D3DBOX
*
pBox
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_LockBox
(
LPDIRECT3DVOLUME9
iface
,
D3DLOCKED_BOX
*
pLockedVolume
,
CONST
D3DBOX
*
pBox
,
DWORD
Flags
)
{
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
TRACE
(
"(%p) relay %p %p %p %ld
\n
"
,
This
,
This
->
wineD3DVolume
,
pLockedVolume
,
pBox
,
Flags
);
return
IWineD3DVolume_LockBox
(
This
->
wineD3DVolume
,
pLockedVolume
,
pBox
,
Flags
);
return
IWineD3DVolume_LockBox
(
This
->
wineD3DVolume
,
pLockedVolume
,
pBox
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DVolume9Impl_UnlockBox
(
LPDIRECT3DVOLUME9
iface
)
{
HRESULT
WINAPI
IDirect3DVolume9Impl_UnlockBox
(
LPDIRECT3DVOLUME9
iface
)
{
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
IDirect3DVolume9Impl
*
This
=
(
IDirect3DVolume9Impl
*
)
iface
;
TRACE
(
"(%p) relay %p
\n
"
,
This
,
This
->
wineD3DVolume
);
return
IWineD3DVolume_UnlockBox
(
This
->
wineD3DVolume
);
return
IWineD3DVolume_UnlockBox
(
This
->
wineD3DVolume
);
}
}
...
@@ -146,6 +154,7 @@ IDirect3DVolume9Vtbl Direct3DVolume9_Vtbl =
...
@@ -146,6 +154,7 @@ IDirect3DVolume9Vtbl Direct3DVolume9_Vtbl =
IDirect3DVolume9Impl_UnlockBox
IDirect3DVolume9Impl_UnlockBox
};
};
/* Internal function called back during the CreateVolumeTexture */
/* Internal function called back during the CreateVolumeTexture */
HRESULT
WINAPI
D3D9CB_CreateVolume
(
IUnknown
*
pDevice
,
UINT
Width
,
UINT
Height
,
UINT
Depth
,
HRESULT
WINAPI
D3D9CB_CreateVolume
(
IUnknown
*
pDevice
,
UINT
Width
,
UINT
Height
,
UINT
Depth
,
D3DFORMAT
Format
,
D3DPOOL
Pool
,
DWORD
Usage
,
D3DFORMAT
Format
,
D3DPOOL
Pool
,
DWORD
Usage
,
...
@@ -166,14 +175,15 @@ HRESULT WINAPI D3D9CB_CreateVolume(IUnknown *pDevice, UINT Width, UINT Height,
...
@@ -166,14 +175,15 @@ HRESULT WINAPI D3D9CB_CreateVolume(IUnknown *pDevice, UINT Width, UINT Height,
object
->
lpVtbl
=
&
Direct3DVolume9_Vtbl
;
object
->
lpVtbl
=
&
Direct3DVolume9_Vtbl
;
object
->
ref
=
1
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVolume
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Usage
,
Format
,
hrc
=
IWineD3DDevice_CreateVolume
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Usage
,
Format
,
Pool
,
pp
Volume
,
pSharedHandle
,
(
IUnknown
*
)
object
);
Pool
,
&
object
->
wineD3D
Volume
,
pSharedHandle
,
(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
)
{
if
(
hrc
!=
D3D_OK
)
{
/* free up object */
/* free up object */
FIXME
(
"(%p) call to IWineD3DDevice_CreateVolume failed
\n
"
,
This
);
FIXME
(
"(%p) call to IWineD3DDevice_CreateVolume failed
\n
"
,
This
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
HeapFree
(
GetProcessHeap
(),
0
,
object
);
*
ppVolume
=
NULL
;
*
ppVolume
=
NULL
;
}
else
{
}
else
{
*
ppVolume
=
(
IWineD3DVolume
*
)
object
;
*
ppVolume
=
(
IWineD3DVolume
*
)
object
->
wineD3DVolume
;
}
}
TRACE
(
"(%p) Created volume %p
\n
"
,
This
,
*
ppVolume
);
return
hrc
;
return
hrc
;
}
}
dlls/d3d9/volumetexture.c
View file @
8435f6f0
...
@@ -22,17 +22,17 @@
...
@@ -22,17 +22,17 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/* IDirect3DVolumeTexture9 IUnknown parts follow: */
/* IDirect3DVolumeTexture9 IUnknown parts follow: */
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_QueryInterface
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_QueryInterface
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFIID
riid
,
LPVOID
*
ppobj
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
if
(
IsEqualGUID
(
riid
,
&
IID_IUnknown
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DResource9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DBaseTexture9
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DVolumeTexture9
))
{
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DVolumeTexture9
))
{
I
Direct3DVolumeTexture9Impl
_AddRef
(
iface
);
I
Unknown
_AddRef
(
iface
);
*
ppobj
=
This
;
*
ppobj
=
This
;
return
D3D_OK
;
return
D3D_OK
;
}
}
...
@@ -66,72 +66,86 @@ ULONG WINAPI IDirect3DVolumeTexture9Impl_Release(LPDIRECT3DVOLUMETEXTURE9 iface)
...
@@ -66,72 +66,86 @@ ULONG WINAPI IDirect3DVolumeTexture9Impl_Release(LPDIRECT3DVOLUMETEXTURE9 iface)
/* IDirect3DVolumeTexture9 IDirect3DResource9 Interface follow: */
/* IDirect3DVolumeTexture9 IDirect3DResource9 Interface follow: */
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_GetDevice
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_GetDevice
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
IDirect3DDevice9
**
ppDevice
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
return
IDirect3DResource9Impl_GetDevice
((
LPDIRECT3DRESOURCE9
)
This
,
ppDevice
);
}
}
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_SetPrivateData
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_SetPrivateData
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFGUID
refguid
,
CONST
void
*
pData
,
DWORD
SizeOfData
,
DWORD
Flags
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
return
IWineD3DVolumeTexture_SetPrivateData
(
This
->
wineD3DVolumeTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_SetPrivateData
(
This
->
wineD3DVolumeTexture
,
refguid
,
pData
,
SizeOfData
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_GetPrivateData
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_GetPrivateData
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFGUID
refguid
,
void
*
pData
,
DWORD
*
pSizeOfData
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
return
IWineD3DVolumeTexture_GetPrivateData
(
This
->
wineD3DVolumeTexture
,
refguid
,
pData
,
pSizeOfData
);
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GetPrivateData
(
This
->
wineD3DVolumeTexture
,
refguid
,
pData
,
pSizeOfData
);
}
}
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_FreePrivateData
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFGUID
refguid
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_FreePrivateData
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
REFGUID
refguid
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
return
IWineD3DVolumeTexture_FreePrivateData
(
This
->
wineD3DVolumeTexture
,
refguid
);
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_FreePrivateData
(
This
->
wineD3DVolumeTexture
,
refguid
);
}
}
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_SetPriority
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
DWORD
PriorityNew
)
{
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_SetPriority
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
DWORD
PriorityNew
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_SetPriority
(
This
->
wineD3DVolumeTexture
,
PriorityNew
);
return
IWineD3DVolumeTexture_SetPriority
(
This
->
wineD3DVolumeTexture
,
PriorityNew
);
}
}
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_GetPriority
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_GetPriority
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GetPriority
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_GetPriority
(
This
->
wineD3DVolumeTexture
);
}
}
void
WINAPI
IDirect3DVolumeTexture9Impl_PreLoad
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
void
WINAPI
IDirect3DVolumeTexture9Impl_PreLoad
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_PreLoad
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_PreLoad
(
This
->
wineD3DVolumeTexture
);
}
}
D3DRESOURCETYPE
WINAPI
IDirect3DVolumeTexture9Impl_GetType
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
D3DRESOURCETYPE
WINAPI
IDirect3DVolumeTexture9Impl_GetType
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GetType
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_GetType
(
This
->
wineD3DVolumeTexture
);
}
}
/* IDirect3DVolumeTexture9 IDirect3DBaseTexture9 Interface follow: */
/* IDirect3DVolumeTexture9 IDirect3DBaseTexture9 Interface follow: */
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_SetLOD
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
DWORD
LODNew
)
{
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_SetLOD
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
DWORD
LODNew
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_SetLOD
(
This
->
wineD3DVolumeTexture
,
LODNew
);
return
IWineD3DVolumeTexture_SetLOD
(
This
->
wineD3DVolumeTexture
,
LODNew
);
}
}
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_GetLOD
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_GetLOD
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GetLOD
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_GetLOD
(
This
->
wineD3DVolumeTexture
);
}
}
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_GetLevelCount
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
DWORD
WINAPI
IDirect3DVolumeTexture9Impl_GetLevelCount
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GetLevelCount
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_GetLevelCount
(
This
->
wineD3DVolumeTexture
);
}
}
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_SetAutoGenFilterType
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
D3DTEXTUREFILTERTYPE
FilterType
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_SetAutoGenFilterType
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
D3DTEXTUREFILTERTYPE
FilterType
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_SetAutoGenFilterType
(
This
->
wineD3DVolumeTexture
,
FilterType
);
return
IWineD3DVolumeTexture_SetAutoGenFilterType
(
This
->
wineD3DVolumeTexture
,
FilterType
);
}
}
D3DTEXTUREFILTERTYPE
WINAPI
IDirect3DVolumeTexture9Impl_GetAutoGenFilterType
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
D3DTEXTUREFILTERTYPE
WINAPI
IDirect3DVolumeTexture9Impl_GetAutoGenFilterType
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GetAutoGenFilterType
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_GetAutoGenFilterType
(
This
->
wineD3DVolumeTexture
);
}
}
void
WINAPI
IDirect3DVolumeTexture9Impl_GenerateMipSubLevels
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
void
WINAPI
IDirect3DVolumeTexture9Impl_GenerateMipSubLevels
(
LPDIRECT3DVOLUMETEXTURE9
iface
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_GenerateMipSubLevels
(
This
->
wineD3DVolumeTexture
);
return
IWineD3DVolumeTexture_GenerateMipSubLevels
(
This
->
wineD3DVolumeTexture
);
}
}
...
@@ -141,6 +155,8 @@ HRESULT WINAPI IDirect3DVolumeTexture9Impl_GetLevelDesc(LPDIRECT3DVOLUMETEXTURE9
...
@@ -141,6 +155,8 @@ HRESULT WINAPI IDirect3DVolumeTexture9Impl_GetLevelDesc(LPDIRECT3DVOLUMETEXTURE9
WINED3DVOLUME_DESC
wined3ddesc
;
WINED3DVOLUME_DESC
wined3ddesc
;
UINT
tmpInt
=
-
1
;
UINT
tmpInt
=
-
1
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
/* As d3d8 and d3d9 structures differ, pass in ptrs to where data needs to go */
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Format
=
&
pDesc
->
Format
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
wined3ddesc
.
Type
=
&
pDesc
->
Type
;
...
@@ -157,8 +173,10 @@ HRESULT WINAPI IDirect3DVolumeTexture9Impl_GetLevelDesc(LPDIRECT3DVOLUMETEXTURE9
...
@@ -157,8 +173,10 @@ HRESULT WINAPI IDirect3DVolumeTexture9Impl_GetLevelDesc(LPDIRECT3DVOLUMETEXTURE9
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_GetVolumeLevel
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
UINT
Level
,
IDirect3DVolume9
**
ppVolumeLevel
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_GetVolumeLevel
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
UINT
Level
,
IDirect3DVolume9
**
ppVolumeLevel
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
HRESULT
hrc
=
D3D_OK
;
HRESULT
hrc
=
D3D_OK
;
IWineD3DVolume
*
myVolume
=
NULL
;
IWineD3DVolume
*
myVolume
=
NULL
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
hrc
=
IWineD3DVolumeTexture_GetVolumeLevel
(
This
->
wineD3DVolumeTexture
,
Level
,
&
myVolume
);
hrc
=
IWineD3DVolumeTexture_GetVolumeLevel
(
This
->
wineD3DVolumeTexture
,
Level
,
&
myVolume
);
if
(
hrc
==
D3D_OK
&&
NULL
!=
ppVolumeLevel
)
{
if
(
hrc
==
D3D_OK
&&
NULL
!=
ppVolumeLevel
)
{
IWineD3DVolumeTexture_GetParent
(
myVolume
,
(
IUnknown
**
)
ppVolumeLevel
);
IWineD3DVolumeTexture_GetParent
(
myVolume
,
(
IUnknown
**
)
ppVolumeLevel
);
...
@@ -169,16 +187,19 @@ HRESULT WINAPI IDirect3DVolumeTexture9Impl_GetVolumeLevel(LPDIRECT3DVOLUMETEXTUR
...
@@ -169,16 +187,19 @@ HRESULT WINAPI IDirect3DVolumeTexture9Impl_GetVolumeLevel(LPDIRECT3DVOLUMETEXTUR
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_LockBox
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
UINT
Level
,
D3DLOCKED_BOX
*
pLockedVolume
,
CONST
D3DBOX
*
pBox
,
DWORD
Flags
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_LockBox
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
UINT
Level
,
D3DLOCKED_BOX
*
pLockedVolume
,
CONST
D3DBOX
*
pBox
,
DWORD
Flags
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay %p %p %p %ld
\n
"
,
This
,
This
->
wineD3DVolumeTexture
,
pLockedVolume
,
pBox
,
Flags
);
return
IWineD3DVolumeTexture_LockBox
(
This
->
wineD3DVolumeTexture
,
Level
,
pLockedVolume
,
pBox
,
Flags
);
return
IWineD3DVolumeTexture_LockBox
(
This
->
wineD3DVolumeTexture
,
Level
,
pLockedVolume
,
pBox
,
Flags
);
}
}
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_UnlockBox
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
UINT
Level
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_UnlockBox
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
UINT
Level
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay %p %d
\n
"
,
This
,
This
->
wineD3DVolumeTexture
,
Level
);
return
IWineD3DVolumeTexture_UnlockBox
(
This
->
wineD3DVolumeTexture
,
Level
);
return
IWineD3DVolumeTexture_UnlockBox
(
This
->
wineD3DVolumeTexture
,
Level
);
}
}
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_AddDirtyBox
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
CONST
D3DBOX
*
pDirtyBox
)
{
HRESULT
WINAPI
IDirect3DVolumeTexture9Impl_AddDirtyBox
(
LPDIRECT3DVOLUMETEXTURE9
iface
,
CONST
D3DBOX
*
pDirtyBox
)
{
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
IDirect3DVolumeTexture9Impl
*
This
=
(
IDirect3DVolumeTexture9Impl
*
)
iface
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
return
IWineD3DVolumeTexture_AddDirtyBox
(
This
->
wineD3DVolumeTexture
,
pDirtyBox
);
return
IWineD3DVolumeTexture_AddDirtyBox
(
This
->
wineD3DVolumeTexture
,
pDirtyBox
);
}
}
...
@@ -220,6 +241,8 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
...
@@ -220,6 +241,8 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
IDirect3DDevice9Impl
*
This
=
(
IDirect3DDevice9Impl
*
)
iface
;
HRESULT
hrc
=
D3D_OK
;
HRESULT
hrc
=
D3D_OK
;
TRACE
(
"(%p) Relay
\n
"
,
This
);
/* Allocate the storage for the device */
/* Allocate the storage for the device */
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
IDirect3DVolumeTexture9Impl
));
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
IDirect3DVolumeTexture9Impl
));
if
(
NULL
==
object
)
{
if
(
NULL
==
object
)
{
...
@@ -231,7 +254,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
...
@@ -231,7 +254,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
object
->
lpVtbl
=
&
Direct3DVolumeTexture9_Vtbl
;
object
->
lpVtbl
=
&
Direct3DVolumeTexture9_Vtbl
;
object
->
ref
=
1
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVolumeTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Levels
,
Usage
,
hrc
=
IWineD3DDevice_CreateVolumeTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Levels
,
Usage
,
Format
,
Pool
,
&
(
object
->
wineD3DVolumeTexture
),
pSharedHandle
,
Format
,
Pool
,
&
object
->
wineD3DVolumeTexture
,
pSharedHandle
,
(
IUnknown
*
)
object
,
D3D9CB_CreateVolume
);
(
IUnknown
*
)
object
,
D3D9CB_CreateVolume
);
...
@@ -243,5 +266,6 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
...
@@ -243,5 +266,6 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
}
else
{
}
else
{
*
ppVolumeTexture
=
(
LPDIRECT3DVOLUMETEXTURE9
)
object
;
*
ppVolumeTexture
=
(
LPDIRECT3DVOLUMETEXTURE9
)
object
;
}
}
TRACE
(
"(%p) returning %p
\n
"
,
This
,
*
ppVolumeTexture
);
return
hrc
;
return
hrc
;
}
}
dlls/d3d9/vshaderdeclaration.c
View file @
8435f6f0
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
#include "config.h"
#include "config.h"
#include "d3d9_private.h"
#include "d3d9_private.h"
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
_shader
);
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d
9
);
/**
/**
* DirectX9 SDK download
* DirectX9 SDK download
...
...
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