Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
eef96e89
Commit
eef96e89
authored
Aug 13, 2019
by
Henri Verbeet
Committed by
Alexandre Julliard
Aug 13, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Introduce a separate structure for OpenGL swapchain information.
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
e3e9bdee
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
7 deletions
+25
-7
adapter_gl.c
dlls/wined3d/adapter_gl.c
+6
-4
swapchain.c
dlls/wined3d/swapchain.c
+7
-2
wined3d_private.h
dlls/wined3d/wined3d_private.h
+12
-1
No files found.
dlls/wined3d/adapter_gl.c
View file @
eef96e89
...
...
@@ -4656,7 +4656,7 @@ static void adapter_gl_uninit_3d(struct wined3d_device *device)
static
HRESULT
adapter_gl_create_swapchain
(
struct
wined3d_device
*
device
,
struct
wined3d_swapchain_desc
*
desc
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
,
struct
wined3d_swapchain
**
swapchain
)
{
struct
wined3d_swapchain
*
swapchain_gl
;
struct
wined3d_swapchain
_gl
*
swapchain_gl
;
HRESULT
hr
;
TRACE
(
"device %p, desc %p, parent %p, parent_ops %p, swapchain %p.
\n
"
,
...
...
@@ -4673,15 +4673,17 @@ static HRESULT adapter_gl_create_swapchain(struct wined3d_device *device, struct
}
TRACE
(
"Created swapchain %p.
\n
"
,
swapchain_gl
);
*
swapchain
=
swapchain_gl
;
*
swapchain
=
&
swapchain_gl
->
s
;
return
hr
;
}
static
void
adapter_gl_destroy_swapchain
(
struct
wined3d_swapchain
*
swapchain
)
{
wined3d_swapchain_cleanup
(
swapchain
);
heap_free
(
swapchain
);
struct
wined3d_swapchain_gl
*
swapchain_gl
=
wined3d_swapchain_gl
(
swapchain
);
wined3d_swapchain_gl_cleanup
(
swapchain_gl
);
heap_free
(
swapchain_gl
);
}
static
HRESULT
adapter_gl_create_buffer
(
struct
wined3d_device
*
device
,
...
...
dlls/wined3d/swapchain.c
View file @
eef96e89
...
...
@@ -105,6 +105,11 @@ void wined3d_swapchain_cleanup(struct wined3d_swapchain *swapchain)
}
}
void
wined3d_swapchain_gl_cleanup
(
struct
wined3d_swapchain_gl
*
swapchain_gl
)
{
wined3d_swapchain_cleanup
(
&
swapchain_gl
->
s
);
}
ULONG
CDECL
wined3d_swapchain_incref
(
struct
wined3d_swapchain
*
swapchain
)
{
ULONG
refcount
=
InterlockedIncrement
(
&
swapchain
->
ref
);
...
...
@@ -1031,13 +1036,13 @@ HRESULT wined3d_swapchain_no3d_init(struct wined3d_swapchain *swapchain_no3d, st
return
wined3d_swapchain_init
(
swapchain_no3d
,
device
,
desc
,
parent
,
parent_ops
,
&
swapchain_no3d_ops
);
}
HRESULT
wined3d_swapchain_gl_init
(
struct
wined3d_swapchain
*
swapchain_gl
,
struct
wined3d_device
*
device
,
HRESULT
wined3d_swapchain_gl_init
(
struct
wined3d_swapchain
_gl
*
swapchain_gl
,
struct
wined3d_device
*
device
,
struct
wined3d_swapchain_desc
*
desc
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
)
{
TRACE
(
"swapchain_gl %p, device %p, desc %p, parent %p, parent_ops %p.
\n
"
,
swapchain_gl
,
device
,
desc
,
parent
,
parent_ops
);
return
wined3d_swapchain_init
(
swapchain_gl
,
device
,
desc
,
parent
,
parent_ops
,
&
swapchain_gl_ops
);
return
wined3d_swapchain_init
(
&
swapchain_gl
->
s
,
device
,
desc
,
parent
,
parent_ops
,
&
swapchain_gl_ops
);
}
HRESULT
wined3d_swapchain_vk_init
(
struct
wined3d_swapchain
*
swapchain_vk
,
struct
wined3d_device
*
device
,
...
...
dlls/wined3d/wined3d_private.h
View file @
eef96e89
...
...
@@ -4422,7 +4422,18 @@ HRESULT wined3d_swapchain_no3d_init(struct wined3d_swapchain *swapchain_no3d,
struct
wined3d_device
*
device
,
struct
wined3d_swapchain_desc
*
desc
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
)
DECLSPEC_HIDDEN
;
HRESULT
wined3d_swapchain_gl_init
(
struct
wined3d_swapchain
*
swapchain_gl
,
struct
wined3d_swapchain_gl
{
struct
wined3d_swapchain
s
;
};
static
inline
struct
wined3d_swapchain_gl
*
wined3d_swapchain_gl
(
struct
wined3d_swapchain
*
swapchain
)
{
return
CONTAINING_RECORD
(
swapchain
,
struct
wined3d_swapchain_gl
,
s
);
}
void
wined3d_swapchain_gl_cleanup
(
struct
wined3d_swapchain_gl
*
swapchain_gl
)
DECLSPEC_HIDDEN
;
HRESULT
wined3d_swapchain_gl_init
(
struct
wined3d_swapchain_gl
*
swapchain_gl
,
struct
wined3d_device
*
device
,
struct
wined3d_swapchain_desc
*
desc
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
)
DECLSPEC_HIDDEN
;
...
...
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