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
d52a75a7
Commit
d52a75a7
authored
Dec 03, 2020
by
Henri Verbeet
Committed by
Alexandre Julliard
Dec 03, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Explicitly synchronise in wined3d_context_gl_map_bo_address().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
5333cd06
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
9 deletions
+11
-9
buffer.c
dlls/wined3d/buffer.c
+0
-7
context_gl.c
dlls/wined3d/context_gl.c
+9
-0
resource.c
dlls/wined3d/resource.c
+2
-2
No files found.
dlls/wined3d/buffer.c
View file @
d52a75a7
...
...
@@ -741,7 +741,6 @@ void * CDECL wined3d_buffer_get_parent(const struct wined3d_buffer *buffer)
static
void
wined3d_buffer_gl_sync_apple
(
struct
wined3d_buffer_gl
*
buffer_gl
,
uint32_t
flags
,
struct
wined3d_context_gl
*
context_gl
)
{
struct
wined3d_device_gl
*
device_gl
=
wined3d_device_gl
(
buffer_gl
->
b
.
resource
.
device
);
const
struct
wined3d_gl_info
*
gl_info
=
context_gl
->
gl_info
;
struct
wined3d_bo_gl
*
bo
=
&
buffer_gl
->
bo
;
...
...
@@ -759,12 +758,6 @@ static void wined3d_buffer_gl_sync_apple(struct wined3d_buffer_gl *buffer_gl,
bo
->
command_fence_id
=
0
;
return
;
}
TRACE
(
"Synchronizing buffer %p.
\n
"
,
buffer_gl
);
if
(
bo
->
command_fence_id
==
device_gl
->
current_fence_id
)
wined3d_context_gl_submit_command_fence
(
context_gl
);
wined3d_context_gl_wait_command_fence
(
context_gl
,
bo
->
command_fence_id
);
}
static
void
buffer_mark_used
(
struct
wined3d_buffer
*
buffer
)
...
...
dlls/wined3d/context_gl.c
View file @
d52a75a7
...
...
@@ -2653,6 +2653,7 @@ void wined3d_context_gl_submit_command_fence(struct wined3d_context_gl *context_
void
*
wined3d_context_gl_map_bo_address
(
struct
wined3d_context_gl
*
context_gl
,
const
struct
wined3d_bo_address
*
data
,
size_t
size
,
uint32_t
flags
)
{
struct
wined3d_device_gl
*
device_gl
=
wined3d_device_gl
(
context_gl
->
c
.
device
);
const
struct
wined3d_gl_info
*
gl_info
;
struct
wined3d_bo_gl
*
bo
;
BYTE
*
memory
;
...
...
@@ -2660,6 +2661,14 @@ void *wined3d_context_gl_map_bo_address(struct wined3d_context_gl *context_gl,
if
(
!
(
bo
=
(
struct
wined3d_bo_gl
*
)
data
->
buffer_object
))
return
data
->
addr
;
if
(
flags
&
(
WINED3D_MAP_DISCARD
|
WINED3D_MAP_NOOVERWRITE
))
goto
map
;
if
(
bo
->
command_fence_id
==
device_gl
->
current_fence_id
)
wined3d_context_gl_submit_command_fence
(
context_gl
);
wined3d_context_gl_wait_command_fence
(
context_gl
,
bo
->
command_fence_id
);
map:
gl_info
=
context_gl
->
gl_info
;
wined3d_context_gl_bind_bo
(
context_gl
,
bo
->
binding
,
bo
->
id
);
...
...
dlls/wined3d/resource.c
View file @
d52a75a7
...
...
@@ -451,11 +451,11 @@ GLbitfield wined3d_resource_gl_map_flags(DWORD d3d_flags)
ret
|=
GL_MAP_WRITE_BIT
|
GL_MAP_FLUSH_EXPLICIT_BIT
;
if
(
d3d_flags
&
WINED3D_MAP_READ
)
ret
|=
GL_MAP_READ_BIT
;
else
if
(
!
(
d3d_flags
&
WINED3D_MAP_DISCARD
))
ret
|=
GL_MAP_UNSYNCHRONIZED_BIT
;
if
(
d3d_flags
&
WINED3D_MAP_DISCARD
)
ret
|=
GL_MAP_INVALIDATE_BUFFER_BIT
;
if
(
d3d_flags
&
WINED3D_MAP_NOOVERWRITE
)
ret
|=
GL_MAP_UNSYNCHRONIZED_BIT
;
return
ret
;
}
...
...
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