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
5d6b7e4c
Commit
5d6b7e4c
authored
Oct 23, 2008
by
Henri Verbeet
Committed by
Alexandre Julliard
Oct 24, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d10: Implement D3D10CreateDeviceAndSwapChain().
parent
c7e1c090
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
55 additions
and
2 deletions
+55
-2
Makefile.in
dlls/d3d10/Makefile.in
+1
-1
d3d10.spec
dlls/d3d10/d3d10.spec
+1
-1
d3d10_main.c
dlls/d3d10/d3d10_main.c
+49
-0
d3d10misc.h
include/d3d10misc.h
+4
-0
No files found.
dlls/d3d10/Makefile.in
View file @
5d6b7e4c
...
@@ -4,7 +4,7 @@ SRCDIR = @srcdir@
...
@@ -4,7 +4,7 @@ SRCDIR = @srcdir@
VPATH
=
@srcdir@
VPATH
=
@srcdir@
MODULE
=
d3d10.dll
MODULE
=
d3d10.dll
IMPORTLIB
=
d3d10
IMPORTLIB
=
d3d10
IMPORTS
=
dxguid uuid kernel32
IMPORTS
=
dxguid uuid
dxgi
kernel32
C_SRCS
=
\
C_SRCS
=
\
d3d10_main.c
\
d3d10_main.c
\
...
...
dlls/d3d10/d3d10.spec
View file @
5d6b7e4c
...
@@ -2,7 +2,7 @@
...
@@ -2,7 +2,7 @@
@ stub D3D10CompileShader
@ stub D3D10CompileShader
@ stub D3D10CreateBlob
@ stub D3D10CreateBlob
@ stdcall D3D10CreateDevice(ptr long ptr long long ptr)
@ stdcall D3D10CreateDevice(ptr long ptr long long ptr)
@ st
ub D3D10CreateDeviceAndSwapChain
@ st
dcall D3D10CreateDeviceAndSwapChain(ptr long ptr long long ptr ptr ptr)
@ stub D3D10CreateEffectFromMemory
@ stub D3D10CreateEffectFromMemory
@ stub D3D10CreateEffectPoolFromMemory
@ stub D3D10CreateEffectPoolFromMemory
@ stub D3D10CreateStateBlock
@ stub D3D10CreateStateBlock
...
...
dlls/d3d10/d3d10_main.c
View file @
5d6b7e4c
...
@@ -64,3 +64,52 @@ HRESULT WINAPI D3D10CreateDevice(IDXGIAdapter *adapter, D3D10_DRIVER_TYPE driver
...
@@ -64,3 +64,52 @@ HRESULT WINAPI D3D10CreateDevice(IDXGIAdapter *adapter, D3D10_DRIVER_TYPE driver
return
S_OK
;
return
S_OK
;
}
}
HRESULT
WINAPI
D3D10CreateDeviceAndSwapChain
(
IDXGIAdapter
*
adapter
,
D3D10_DRIVER_TYPE
driver_type
,
HMODULE
swrast
,
UINT
flags
,
UINT
sdk_version
,
DXGI_SWAP_CHAIN_DESC
*
swapchain_desc
,
IDXGISwapChain
**
swapchain
,
ID3D10Device
**
device
)
{
IDXGIFactory
*
factory
;
HRESULT
hr
;
TRACE
(
"adapter %p, driver_type %s, swrast %p, flags %#x, sdk_version %d,
\n
"
"
\t
swapchain_desc %p, swapchain %p, device %p
\n
"
,
adapter
,
debug_d3d10_driver_type
(
driver_type
),
swrast
,
flags
,
sdk_version
,
swapchain_desc
,
swapchain
,
device
);
hr
=
D3D10CreateDevice
(
adapter
,
driver_type
,
swrast
,
flags
,
sdk_version
,
device
);
if
(
FAILED
(
hr
))
{
WARN
(
"Failed to create a device, returning %#x
\n
"
,
hr
);
return
hr
;
}
TRACE
(
"Created ID3D10Device %p
\n
"
,
*
device
);
hr
=
CreateDXGIFactory
(
&
IID_IDXGIFactory
,
(
void
**
)
&
factory
);
if
(
FAILED
(
hr
))
{
ID3D10Device_Release
(
*
device
);
*
device
=
NULL
;
WARN
(
"Failed to create a DXGI factory, returning %#x
\n
"
,
hr
);
return
hr
;
}
TRACE
(
"Created IDXGIFactory %p
\n
"
,
factory
);
hr
=
IDXGIFactory_CreateSwapChain
(
factory
,
(
IUnknown
*
)
*
device
,
swapchain_desc
,
swapchain
);
IDXGIFactory_Release
(
factory
);
if
(
FAILED
(
hr
))
{
ID3D10Device_Release
(
*
device
);
*
device
=
NULL
;
WARN
(
"Failed to create a swapchain, returning %#x
\n
"
,
hr
);
return
hr
;
}
TRACE
(
"Created IDXGISwapChain %p
\n
"
,
*
swapchain
);
return
S_OK
;
}
include/d3d10misc.h
View file @
5d6b7e4c
...
@@ -35,6 +35,10 @@ typedef enum D3D10_DRIVER_TYPE {
...
@@ -35,6 +35,10 @@ typedef enum D3D10_DRIVER_TYPE {
HRESULT
WINAPI
D3D10CreateDevice
(
IDXGIAdapter
*
adapter
,
D3D10_DRIVER_TYPE
driver_type
,
HRESULT
WINAPI
D3D10CreateDevice
(
IDXGIAdapter
*
adapter
,
D3D10_DRIVER_TYPE
driver_type
,
HMODULE
swrast
,
UINT
flags
,
UINT
sdk_version
,
ID3D10Device
**
device
);
HMODULE
swrast
,
UINT
flags
,
UINT
sdk_version
,
ID3D10Device
**
device
);
HRESULT
WINAPI
D3D10CreateDeviceAndSwapChain
(
IDXGIAdapter
*
adapter
,
D3D10_DRIVER_TYPE
driver_type
,
HMODULE
swrast
,
UINT
flags
,
UINT
sdk_version
,
DXGI_SWAP_CHAIN_DESC
*
swapchain_desc
,
IDXGISwapChain
**
swapchain
,
ID3D10Device
**
device
);
#ifdef __cplusplus
#ifdef __cplusplus
}
}
#endif
#endif
...
...
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