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
d2510847
Commit
d2510847
authored
Apr 12, 2006
by
Stefan Dösinger
Committed by
Alexandre Julliard
Apr 13, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Split device creation and opengl initialization.
parent
59189ba7
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
46 additions
and
7 deletions
+46
-7
device.c
dlls/d3d8/device.c
+3
-0
directx.c
dlls/d3d8/directx.c
+14
-4
device.c
dlls/d3d9/device.c
+3
-0
directx.c
dlls/d3d9/directx.c
+12
-3
device.c
dlls/wined3d/device.c
+12
-0
wined3d_interface.h
include/wine/wined3d_interface.h
+2
-0
No files found.
dlls/d3d8/device.c
View file @
d2510847
...
...
@@ -69,6 +69,9 @@ ULONG WINAPI IDirect3DDevice8Impl_Release(LPDIRECT3DDEVICE8 iface) {
if
(
ref
==
0
)
{
TRACE
(
"Releasing wined3d device %p
\n
"
,
This
->
WineD3DDevice
);
/* Activate this when it's implemented in wined3d(d3d7 merge)
IWineD3DDevice_Uninit3D(This->WineD3DDevice);
*/
IWineD3DDevice_Release
(
This
->
WineD3DDevice
);
HeapFree
(
GetProcessHeap
(),
0
,
This
);
}
...
...
dlls/d3d8/directx.c
View file @
d2510847
...
...
@@ -324,13 +324,23 @@ HRESULT WINAPI IDirect3D8Impl_CreateDevice(LPDIRECT3D8 iface, UINT Adapter, D3
localParameters
.
PresentationInterval
=
&
pPresentationParameters
->
FullScreen_PresentationInterval
;
/* Renamed in dx9 */
hr
=
IWineD3D_CreateDevice
(
This
->
WineD3D
,
Adapter
,
DeviceType
,
hFocusWindow
,
BehaviourFlags
,
&
localParameters
,
&
object
->
WineD3DDevice
,
(
IUnknown
*
)
object
,
D3D8CB_CreateAdditionalSwapChain
);
if
(
hr
==
D3D_OK
)
{
TRACE
(
"(%p) : Created Device %p
\n
"
,
This
,
object
);
}
else
{
if
(
hr
!=
D3D_OK
)
{
HeapFree
(
GetProcessHeap
(),
0
,
object
);
*
ppReturnedDeviceInterface
=
NULL
;
return
hr
;
}
TRACE
(
"(%p) : Created Device %p
\n
"
,
This
,
object
);
/* Activate this when it's implemented in wined3d(d3d7 merge)
hr = IWineD3DDevice_Init3D(object->WineD3DDevice, &localParameters, D3D8CB_CreateAdditionalSwapChain);
if (hr != D3D_OK) {
FIXME("(%p) D3D Initialization failed for WineD3DDevice %p\n", This, object->WineD3DDevice);
HeapFree(GetProcessHeap(), 0, object);
*ppReturnedDeviceInterface = NULL;
}
*/
return
hr
;
}
...
...
dlls/d3d9/device.c
View file @
d2510847
...
...
@@ -57,6 +57,9 @@ ULONG WINAPI IDirect3DDevice9Impl_Release(LPDIRECT3DDEVICE9 iface) {
TRACE
(
"(%p) : ReleaseRef to %ld
\n
"
,
This
,
ref
);
if
(
ref
==
0
)
{
/* Activate this when it's implemented in WineD3D(d3d7 merge)
IWineD3DDevice_Uninit3D(This->WineD3DDevice);
*/
IWineD3DDevice_Release
(
This
->
WineD3DDevice
);
HeapFree
(
GetProcessHeap
(),
0
,
This
);
}
...
...
dlls/d3d9/directx.c
View file @
d2510847
...
...
@@ -309,13 +309,22 @@ HRESULT WINAPI IDirect3D9Impl_CreateDevice(LPDIRECT3D9 iface, UINT Adapter, D3
hr
=
IWineD3D_CreateDevice
(
This
->
WineD3D
,
Adapter
,
DeviceType
,
hFocusWindow
,
BehaviourFlags
,
&
localParameters
,
&
object
->
WineD3DDevice
,
(
IUnknown
*
)
object
,
D3D9CB_CreateAdditionalSwapChain
);
if
(
hr
==
D3D_OK
)
{
if
(
hr
!=
D3D_OK
)
{
HeapFree
(
GetProcessHeap
(),
0
,
object
);
*
ppReturnedDeviceInterface
=
NULL
;
return
hr
;
}
TRACE
(
"(%p) : Created Device %p
\n
"
,
This
,
object
);
}
else
{
TRACE
(
"(%p) : Created Device %p
\n
"
,
This
,
object
);
/* Activate this when it's implemented in wined3d(d3d7 merge)
hr = IWineD3DDevice_Init3D(object->WineD3DDevice, &localParameters, D3D8CB_CreateAdditionalSwapChain);
if (hr != D3D_OK) {
FIXME("(%p) D3D Initialization failed for WineD3DDevice %p\n", This, object->WineD3DDevice);
HeapFree(GetProcessHeap(), 0, object);
*ppReturnedDeviceInterface = NULL;
}
*/
return
hr
;
}
...
...
dlls/wined3d/device.c
View file @
d2510847
...
...
@@ -1668,6 +1668,16 @@ HRESULT WINAPI IWineD3DDeviceImpl_CreatePixelShader(IWineD3DDevice *iface, CONST
return
hr
;
}
HRESULT
WINAPI
IWineD3DDeviceImpl_Init3D
(
IWineD3DDevice
*
iface
,
WINED3DPRESENT_PARAMETERS
*
pPresentationParameters
,
D3DCB_CREATEADDITIONALSWAPCHAIN
D3DCB_CreateAdditionalSwapChain
)
{
FIXME
(
"This call is a d3d7 merge stub. It will be implemented later
\n
"
);
return
WINED3DERR_INVALIDCALL
;
}
HRESULT
WINAPI
IWineD3DDeviceImpl_Uninit3D
(
IWineD3DDevice
*
iface
)
{
FIXME
(
"This call is a d3d7 merge stub. It will be implemented later
\n
"
);
return
WINED3DERR_INVALIDCALL
;
}
HRESULT
WINAPI
IWineD3DDeviceImpl_GetDirect3D
(
IWineD3DDevice
*
iface
,
IWineD3D
**
ppD3D
)
{
IWineD3DDeviceImpl
*
This
=
(
IWineD3DDeviceImpl
*
)
iface
;
*
ppD3D
=
This
->
wineD3D
;
...
...
@@ -6792,6 +6802,8 @@ const IWineD3DDeviceVtbl IWineD3DDevice_Vtbl =
IWineD3DDeviceImpl_CreateVertexShader
,
IWineD3DDeviceImpl_CreatePixelShader
,
/*** Odd functions **/
IWineD3DDeviceImpl_Init3D
,
IWineD3DDeviceImpl_Uninit3D
,
IWineD3DDeviceImpl_EvictManagedResources
,
IWineD3DDeviceImpl_GetAvailableTextureMem
,
IWineD3DDeviceImpl_GetBackBuffer
,
...
...
include/wine/wined3d_interface.h
View file @
d2510847
...
...
@@ -362,6 +362,8 @@ DECLARE_INTERFACE_(IWineD3DDevice,IWineD3DBase)
STDMETHOD
(
CreateVertexDeclaration
)(
THIS_
CONST
VOID
*
pDeclaration
,
struct
IWineD3DVertexDeclaration
**
ppDecl
,
IUnknown
*
pParent
)
PURE
;
STDMETHOD
(
CreateVertexShader
)(
THIS_
CONST
DWORD
*
pDeclaration
,
CONST
DWORD
*
pFunction
,
struct
IWineD3DVertexShader
**
ppShader
,
IUnknown
*
pParent
)
PURE
;
STDMETHOD
(
CreatePixelShader
)(
THIS_
CONST
DWORD
*
pFunction
,
struct
IWineD3DPixelShader
**
ppShader
,
IUnknown
*
pParent
)
PURE
;
STDMETHOD
(
Init3D
)(
THIS_
WINED3DPRESENT_PARAMETERS
*
pPresentationParameters
,
D3DCB_CREATEADDITIONALSWAPCHAIN
D3DCB_CreateAdditionalSwapChain
);
STDMETHOD
(
Uninit3D
)(
THIS
);
STDMETHOD
(
EvictManagedResources
)(
THIS
)
PURE
;
STDMETHOD_
(
UINT
,
GetAvailableTextureMem
)(
THIS
)
PURE
;
STDMETHOD
(
GetBackBuffer
)(
THIS_
UINT
iSwapChain
,
UINT
BackBuffer
,
WINED3DBACKBUFFER_TYPE
,
struct
IWineD3DSurface
**
ppBackBuffer
)
PURE
;
...
...
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