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
75aa0b38
Commit
75aa0b38
authored
Apr 02, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
Apr 03, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ddraw: The various D3D device interfaces can't be queried from version 7 surfaces.
parent
8e4acd81
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
18 deletions
+16
-18
surface.c
dlls/ddraw/surface.c
+16
-18
No files found.
dlls/ddraw/surface.c
View file @
75aa0b38
...
@@ -198,32 +198,30 @@ static HRESULT WINAPI ddraw_surface7_QueryInterface(IDirectDrawSurface7 *iface,
...
@@ -198,32 +198,30 @@ static HRESULT WINAPI ddraw_surface7_QueryInterface(IDirectDrawSurface7 *iface,
return
E_NOINTERFACE
;
return
E_NOINTERFACE
;
}
}
if
(
IsEqualGUID
(
riid
,
&
IID_D3DDEVICE_WineD3D
)
if
(
This
->
version
!=
7
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DHALDevice
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DRGBDevice
))
{
{
IDirect3DDevice7
*
d3d
;
if
(
IsEqualGUID
(
riid
,
&
IID_D3DDEVICE_WineD3D
)
IDirect3DDeviceImpl
*
device_impl
;
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DHALDevice
)
||
IsEqualGUID
(
riid
,
&
IID_IDirect3DRGBDevice
))
{
IDirect3DDeviceImpl
*
device_impl
;
IDirect3DDevice7
*
device
;
HRESULT
hr
;
/* Call into IDirect3D7 for creation */
hr
=
IDirect3D7_CreateDevice
(
&
This
->
ddraw
->
IDirect3D7_iface
,
riid
,
IDirect3D7_CreateDevice
(
&
This
->
ddraw
->
IDirect3D7_iface
,
riid
,
&
This
->
IDirectDrawSurface7_iface
,
&
This
->
IDirectDrawSurface7_iface
,
&
device
);
&
d3d
);
if
(
FAILED
(
hr
))
{
WARN
(
"Failed to create device, hr %#x.
\n
"
,
hr
);
return
hr
;
}
if
(
d3d
)
device_impl
=
impl_from_IDirect3DDevice7
(
device
);
{
device_impl
=
impl_from_IDirect3DDevice7
(
d3d
);
device_impl
->
from_surface
=
TRUE
;
device_impl
->
from_surface
=
TRUE
;
*
obj
=
&
device_impl
->
IDirect3DDevice_iface
;
*
obj
=
&
device_impl
->
IDirect3DDevice_iface
;
TRACE
(
"(%p) Returning IDirect3DDevice interface at %p
\n
"
,
This
,
*
obj
);
return
S_OK
;
return
S_OK
;
}
}
WARN
(
"Unable to create a IDirect3DDevice instance, returning E_NOINTERFACE
\n
"
);
return
E_NOINTERFACE
;
}
if
(
This
->
version
!=
7
)
{
if
(
IsEqualGUID
(
&
IID_IDirect3DTexture2
,
riid
))
if
(
IsEqualGUID
(
&
IID_IDirect3DTexture2
,
riid
))
{
{
IDirect3DTexture2_AddRef
(
&
This
->
IDirect3DTexture2_iface
);
IDirect3DTexture2_AddRef
(
&
This
->
IDirect3DTexture2_iface
);
...
...
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