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
df7e680c
Commit
df7e680c
authored
May 22, 2023
by
Nikolay Sivov
Committed by
Alexandre Julliard
May 23, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d2d1: Create GDI-compatible swapchain only for corresponding target usage.
parent
6526de5c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
4 deletions
+3
-4
hwnd_render_target.c
dlls/d2d1/hwnd_render_target.c
+3
-1
d2d1.c
dlls/d2d1/tests/d2d1.c
+0
-3
No files found.
dlls/d2d1/hwnd_render_target.c
View file @
df7e680c
...
...
@@ -889,7 +889,9 @@ HRESULT d2d_hwnd_render_target_init(struct d2d_hwnd_render_target *render_target
swapchain_desc
.
Windowed
=
TRUE
;
swapchain_desc
.
SwapEffect
=
hwnd_rt_desc
->
presentOptions
&
D2D1_PRESENT_OPTIONS_RETAIN_CONTENTS
?
DXGI_SWAP_EFFECT_SEQUENTIAL
:
DXGI_SWAP_EFFECT_DISCARD
;
swapchain_desc
.
Flags
=
DXGI_SWAP_CHAIN_FLAG_GDI_COMPATIBLE
;
swapchain_desc
.
Flags
=
0
;
if
(
desc
->
usage
&
D2D1_RENDER_TARGET_USAGE_GDI_COMPATIBLE
)
swapchain_desc
.
Flags
=
DXGI_SWAP_CHAIN_FLAG_GDI_COMPATIBLE
;
hr
=
IDXGIFactory_CreateSwapChain
(
dxgi_factory
,
(
IUnknown
*
)
d3d_device
,
&
swapchain_desc
,
&
render_target
->
swapchain
);
IDXGIFactory_Release
(
dxgi_factory
);
...
...
dlls/d2d1/tests/d2d1.c
View file @
df7e680c
...
...
@@ -13732,10 +13732,7 @@ static void test_hwnd_target_is_supported(BOOL d3d11)
desc
=
template_desc
;
desc
.
pixelFormat
=
pixel_formats
[
i
];
hr
=
ID2D1Factory_CreateHwndRenderTarget
(
ctx
.
factory
,
&
desc
,
&
hwnd_rt_desc
,
&
rt
);
todo_wine_if
(
i
==
3
||
i
==
4
||
i
==
5
)
ok
(
hr
==
S_OK
,
"%u: unexpected hr %#lx.
\n
"
,
i
,
hr
);
if
(
FAILED
(
hr
))
continue
;
/* Resolve to default format. */
if
(
desc
.
pixelFormat
.
format
==
DXGI_FORMAT_UNKNOWN
)
...
...
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