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
6239db72
Commit
6239db72
authored
Oct 18, 2023
by
Jacek Caban
Committed by
Alexandre Julliard
Oct 20, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d2d1: Don't cast D2D1_THREADING_MODE to D2D1_FACTORY_TYPE in D2D1CreateDevice.
parent
f319d4ce
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
2 deletions
+14
-2
factory.c
dlls/d2d1/factory.c
+14
-2
No files found.
dlls/d2d1/factory.c
View file @
6239db72
...
...
@@ -1308,6 +1308,7 @@ HRESULT WINAPI D2D1CreateDevice(IDXGIDevice *dxgi_device,
{
D2D1_CREATION_PROPERTIES
default_properties
=
{
0
};
D2D1_FACTORY_OPTIONS
factory_options
;
D2D1_FACTORY_TYPE
factory_type
;
ID3D11Device
*
d3d_device
;
ID2D1Factory1
*
factory
;
HRESULT
hr
;
...
...
@@ -1325,9 +1326,20 @@ HRESULT WINAPI D2D1CreateDevice(IDXGIDevice *dxgi_device,
properties
=
&
default_properties
;
}
switch
(
properties
->
threadingMode
)
{
case
D2D1_THREADING_MODE_SINGLE_THREADED
:
factory_type
=
D2D1_FACTORY_TYPE_SINGLE_THREADED
;
break
;
case
D2D1_THREADING_MODE_MULTI_THREADED
:
factory_type
=
D2D1_FACTORY_TYPE_MULTI_THREADED
;
break
;
default:
return
E_INVALIDARG
;
}
factory_options
.
debugLevel
=
properties
->
debugLevel
;
if
(
FAILED
(
hr
=
D2D1CreateFactory
(
properties
->
threadingMode
,
&
IID_ID2D1Factory1
,
&
factory_options
,
(
void
**
)
&
factory
)))
if
(
FAILED
(
hr
=
D2D1CreateFactory
(
factory_type
,
&
IID_ID2D1Factory1
,
&
factory_options
,
(
void
**
)
&
factory
)))
return
hr
;
hr
=
ID2D1Factory1_CreateDevice
(
factory
,
dxgi_device
,
device
);
...
...
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