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
7bdbf00b
Commit
7bdbf00b
authored
Jun 07, 2019
by
Henri Verbeet
Committed by
Alexandre Julliard
Jun 10, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Pass a wined3d_context_gl structure to context_copy_bo_address().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
813e08fc
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
12 deletions
+13
-12
buffer.c
dlls/wined3d/buffer.c
+2
-1
context.c
dlls/wined3d/context.c
+6
-7
view.c
dlls/wined3d/view.c
+2
-1
wined3d_private.h
dlls/wined3d/wined3d_private.h
+3
-3
No files found.
dlls/wined3d/buffer.c
View file @
7bdbf00b
...
@@ -1218,7 +1218,8 @@ void wined3d_buffer_copy(struct wined3d_buffer *dst_buffer, unsigned int dst_off
...
@@ -1218,7 +1218,8 @@ void wined3d_buffer_copy(struct wined3d_buffer *dst_buffer, unsigned int dst_off
src
.
addr
+=
src_offset
;
src
.
addr
+=
src_offset
;
context
=
context_acquire
(
dst_buffer
->
resource
.
device
,
NULL
,
0
);
context
=
context_acquire
(
dst_buffer
->
resource
.
device
,
NULL
,
0
);
context_copy_bo_address
(
context
,
&
dst
,
wined3d_buffer_gl
(
dst_buffer
)
->
buffer_type_hint
,
wined3d_context_gl_copy_bo_address
(
wined3d_context_gl
(
context
),
&
dst
,
wined3d_buffer_gl
(
dst_buffer
)
->
buffer_type_hint
,
&
src
,
wined3d_buffer_gl
(
src_buffer
)
->
buffer_type_hint
,
size
);
&
src
,
wined3d_buffer_gl
(
src_buffer
)
->
buffer_type_hint
,
size
);
context_release
(
context
);
context_release
(
context
);
...
...
dlls/wined3d/context.c
View file @
7bdbf00b
...
@@ -2634,15 +2634,14 @@ void context_unmap_bo_address(struct wined3d_context *context,
...
@@ -2634,15 +2634,14 @@ void context_unmap_bo_address(struct wined3d_context *context,
checkGLcall
(
"Unmap buffer object"
);
checkGLcall
(
"Unmap buffer object"
);
}
}
void
context_copy_bo_address
(
struct
wined3d_context
*
context
,
void
wined3d_context_gl_copy_bo_address
(
struct
wined3d_context_gl
*
context_gl
,
const
struct
wined3d_bo_address
*
dst
,
GLenum
dst_binding
,
const
struct
wined3d_bo_address
*
dst
,
GLenum
dst_binding
,
const
struct
wined3d_bo_address
*
src
,
GLenum
src_binding
,
size_t
size
)
const
struct
wined3d_bo_address
*
src
,
GLenum
src_binding
,
size_t
size
)
{
{
struct
wined3d_context_gl
*
context_gl
=
wined3d_context_gl
(
context
);
const
struct
wined3d_gl_info
*
gl_info
;
const
struct
wined3d_gl_info
*
gl_info
;
BYTE
*
dst_ptr
,
*
src_ptr
;
BYTE
*
dst_ptr
,
*
src_ptr
;
gl_info
=
context
->
gl_info
;
gl_info
=
context
_gl
->
c
.
gl_info
;
if
(
dst
->
buffer_object
&&
src
->
buffer_object
)
if
(
dst
->
buffer_object
&&
src
->
buffer_object
)
{
{
...
@@ -2656,13 +2655,13 @@ void context_copy_bo_address(struct wined3d_context *context,
...
@@ -2656,13 +2655,13 @@ void context_copy_bo_address(struct wined3d_context *context,
}
}
else
else
{
{
src_ptr
=
context_map_bo_address
(
context
,
src
,
size
,
src_binding
,
WINED3D_MAP_READ
);
src_ptr
=
context_map_bo_address
(
&
context_gl
->
c
,
src
,
size
,
src_binding
,
WINED3D_MAP_READ
);
dst_ptr
=
context_map_bo_address
(
context
,
dst
,
size
,
dst_binding
,
WINED3D_MAP_WRITE
);
dst_ptr
=
context_map_bo_address
(
&
context_gl
->
c
,
dst
,
size
,
dst_binding
,
WINED3D_MAP_WRITE
);
memcpy
(
dst_ptr
,
src_ptr
,
size
);
memcpy
(
dst_ptr
,
src_ptr
,
size
);
context_unmap_bo_address
(
context
,
dst
,
dst_binding
);
context_unmap_bo_address
(
&
context_gl
->
c
,
dst
,
dst_binding
);
context_unmap_bo_address
(
context
,
src
,
src_binding
);
context_unmap_bo_address
(
&
context_gl
->
c
,
src
,
src_binding
);
}
}
}
}
else
if
(
!
dst
->
buffer_object
&&
src
->
buffer_object
)
else
if
(
!
dst
->
buffer_object
&&
src
->
buffer_object
)
...
...
dlls/wined3d/view.c
View file @
7bdbf00b
...
@@ -1096,6 +1096,7 @@ void wined3d_unordered_access_view_copy_counter(struct wined3d_unordered_access_
...
@@ -1096,6 +1096,7 @@ void wined3d_unordered_access_view_copy_counter(struct wined3d_unordered_access_
struct
wined3d_buffer
*
buffer
,
unsigned
int
offset
,
struct
wined3d_context
*
context
)
struct
wined3d_buffer
*
buffer
,
unsigned
int
offset
,
struct
wined3d_context
*
context
)
{
{
struct
wined3d_unordered_access_view_gl
*
view_gl
=
wined3d_unordered_access_view_gl
(
view
);
struct
wined3d_unordered_access_view_gl
*
view_gl
=
wined3d_unordered_access_view_gl
(
view
);
struct
wined3d_context_gl
*
context_gl
=
wined3d_context_gl
(
context
);
struct
wined3d_bo_address
dst
,
src
;
struct
wined3d_bo_address
dst
,
src
;
DWORD
dst_location
;
DWORD
dst_location
;
...
@@ -1108,7 +1109,7 @@ void wined3d_unordered_access_view_copy_counter(struct wined3d_unordered_access_
...
@@ -1108,7 +1109,7 @@ void wined3d_unordered_access_view_copy_counter(struct wined3d_unordered_access_
src
.
buffer_object
=
view_gl
->
counter_bo
;
src
.
buffer_object
=
view_gl
->
counter_bo
;
src
.
addr
=
NULL
;
src
.
addr
=
NULL
;
context_copy_bo_address
(
context
,
&
dst
,
wined3d_buffer_gl
(
buffer
)
->
buffer_type_hint
,
wined3d_context_gl_copy_bo_address
(
context_gl
,
&
dst
,
wined3d_buffer_gl
(
buffer
)
->
buffer_type_hint
,
&
src
,
GL_ATOMIC_COUNTER_BUFFER
,
sizeof
(
GLuint
));
&
src
,
GL_ATOMIC_COUNTER_BUFFER
,
sizeof
(
GLuint
));
wined3d_buffer_invalidate_location
(
buffer
,
~
dst_location
);
wined3d_buffer_invalidate_location
(
buffer
,
~
dst_location
);
...
...
dlls/wined3d/wined3d_private.h
View file @
7bdbf00b
...
@@ -2086,6 +2086,9 @@ void wined3d_context_gl_bind_dummy_textures(const struct wined3d_context_gl *con
...
@@ -2086,6 +2086,9 @@ void wined3d_context_gl_bind_dummy_textures(const struct wined3d_context_gl *con
void
wined3d_context_gl_bind_texture
(
struct
wined3d_context_gl
*
context_gl
,
void
wined3d_context_gl_bind_texture
(
struct
wined3d_context_gl
*
context_gl
,
GLenum
target
,
GLuint
name
)
DECLSPEC_HIDDEN
;
GLenum
target
,
GLuint
name
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_check_fbo_status
(
const
struct
wined3d_context_gl
*
context_gl
,
GLenum
target
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_check_fbo_status
(
const
struct
wined3d_context_gl
*
context_gl
,
GLenum
target
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_copy_bo_address
(
struct
wined3d_context_gl
*
context_gl
,
const
struct
wined3d_bo_address
*
dst
,
GLenum
dst_binding
,
const
struct
wined3d_bo_address
*
src
,
GLenum
src_binding
,
size_t
size
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_destroy
(
struct
wined3d_context_gl
*
context_gl
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_destroy
(
struct
wined3d_context_gl
*
context_gl
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_free_fence
(
struct
wined3d_fence
*
fence
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_free_fence
(
struct
wined3d_fence
*
fence
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_free_occlusion_query
(
struct
wined3d_occlusion_query
*
query
)
DECLSPEC_HIDDEN
;
void
wined3d_context_gl_free_occlusion_query
(
struct
wined3d_occlusion_query
*
query
)
DECLSPEC_HIDDEN
;
...
@@ -2239,9 +2242,6 @@ void wined3d_raw_blitter_create(struct wined3d_blitter **next,
...
@@ -2239,9 +2242,6 @@ void wined3d_raw_blitter_create(struct wined3d_blitter **next,
BOOL
wined3d_clip_blit
(
const
RECT
*
clip_rect
,
RECT
*
clipped
,
RECT
*
other
)
DECLSPEC_HIDDEN
;
BOOL
wined3d_clip_blit
(
const
RECT
*
clip_rect
,
RECT
*
clipped
,
RECT
*
other
)
DECLSPEC_HIDDEN
;
void
context_copy_bo_address
(
struct
wined3d_context
*
context
,
const
struct
wined3d_bo_address
*
dst
,
GLenum
dst_binding
,
const
struct
wined3d_bo_address
*
src
,
GLenum
src_binding
,
size_t
size
)
DECLSPEC_HIDDEN
;
HGLRC
context_create_wgl_attribs
(
const
struct
wined3d_gl_info
*
gl_info
,
HDC
hdc
,
HGLRC
share_ctx
)
DECLSPEC_HIDDEN
;
HGLRC
context_create_wgl_attribs
(
const
struct
wined3d_gl_info
*
gl_info
,
HDC
hdc
,
HGLRC
share_ctx
)
DECLSPEC_HIDDEN
;
void
context_draw_shaded_quad
(
struct
wined3d_context
*
context
,
struct
wined3d_texture_gl
*
texture_gl
,
void
context_draw_shaded_quad
(
struct
wined3d_context
*
context
,
struct
wined3d_texture_gl
*
texture_gl
,
unsigned
int
sub_resource_idx
,
const
RECT
*
src_rect
,
const
RECT
*
dst_rect
,
unsigned
int
sub_resource_idx
,
const
RECT
*
src_rect
,
const
RECT
*
dst_rect
,
...
...
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