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
c22c9b40
Commit
c22c9b40
authored
Apr 22, 2016
by
Stefan Dösinger
Committed by
Alexandre Julliard
Apr 25, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Use wined3d_texture_prepare_location() in surface_blt_fbo().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
b6b7e237
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
7 deletions
+9
-7
surface.c
dlls/wined3d/surface.c
+9
-7
No files found.
dlls/wined3d/surface.c
View file @
c22c9b40
...
...
@@ -502,6 +502,9 @@ static void surface_blt_fbo(const struct wined3d_device *device,
struct
wined3d_surface
*
src_surface
,
DWORD
src_location
,
const
RECT
*
src_rect_in
,
struct
wined3d_surface
*
dst_surface
,
DWORD
dst_location
,
const
RECT
*
dst_rect_in
)
{
unsigned
int
dst_sub_resource_idx
=
surface_get_sub_resource_idx
(
dst_surface
);
struct
wined3d_texture
*
dst_texture
=
dst_surface
->
container
;
struct
wined3d_texture
*
src_texture
=
src_surface
->
container
;
const
struct
wined3d_gl_info
*
gl_info
;
struct
wined3d_context
*
context
=
old_ctx
;
struct
wined3d_surface
*
required_rt
,
*
restore_rt
=
NULL
;
...
...
@@ -534,7 +537,7 @@ static void surface_blt_fbo(const struct wined3d_device *device,
/* Resolve the source surface first if needed. */
if
(
src_location
==
WINED3D_LOCATION_RB_MULTISAMPLE
&&
(
src_
surface
->
container
->
resource
.
format
->
id
!=
dst_surface
->
container
->
resource
.
format
->
id
&&
(
src_
texture
->
resource
.
format
->
id
!=
dst_texture
->
resource
.
format
->
id
||
abs
(
src_rect
.
bottom
-
src_rect
.
top
)
!=
abs
(
dst_rect
.
bottom
-
dst_rect
.
top
)
||
abs
(
src_rect
.
right
-
src_rect
.
left
)
!=
abs
(
dst_rect
.
right
-
dst_rect
.
left
)))
src_location
=
WINED3D_LOCATION_RB_RESOLVED
;
...
...
@@ -547,7 +550,7 @@ static void surface_blt_fbo(const struct wined3d_device *device,
if
(
!
surface_is_full_rect
(
dst_surface
,
&
dst_rect
))
surface_load_location
(
dst_surface
,
old_ctx
,
dst_location
);
else
wined3d_
surface_prepare
(
dst_surface
,
old_ctx
,
dst_location
);
wined3d_
texture_prepare_location
(
dst_texture
,
dst_sub_resource_idx
,
old_ctx
,
dst_location
);
if
(
src_location
==
WINED3D_LOCATION_DRAWABLE
)
required_rt
=
src_surface
;
...
...
@@ -572,7 +575,7 @@ static void surface_blt_fbo(const struct wined3d_device *device,
if
(
src_location
==
WINED3D_LOCATION_DRAWABLE
)
{
TRACE
(
"Source surface %p is onscreen.
\n
"
,
src_surface
);
buffer
=
wined3d_texture_get_gl_buffer
(
src_
surface
->
container
);
buffer
=
wined3d_texture_get_gl_buffer
(
src_
texture
);
surface_translate_drawable_coords
(
src_surface
,
context
->
win_handle
,
&
src_rect
);
}
else
...
...
@@ -589,7 +592,7 @@ static void surface_blt_fbo(const struct wined3d_device *device,
if
(
dst_location
==
WINED3D_LOCATION_DRAWABLE
)
{
TRACE
(
"Destination surface %p is onscreen.
\n
"
,
dst_surface
);
buffer
=
wined3d_texture_get_gl_buffer
(
dst_
surface
->
container
);
buffer
=
wined3d_texture_get_gl_buffer
(
dst_
texture
);
surface_translate_drawable_coords
(
dst_surface
,
context
->
win_handle
,
&
dst_rect
);
}
else
...
...
@@ -616,9 +619,8 @@ static void surface_blt_fbo(const struct wined3d_device *device,
dst_rect
.
left
,
dst_rect
.
top
,
dst_rect
.
right
,
dst_rect
.
bottom
,
GL_COLOR_BUFFER_BIT
,
gl_filter
);
checkGLcall
(
"glBlitFramebuffer()"
);
if
(
wined3d_settings
.
strict_draw_ordering
||
(
dst_location
==
WINED3D_LOCATION_DRAWABLE
&&
dst_surface
->
container
->
swapchain
->
front_buffer
==
dst_surface
->
container
))
if
(
wined3d_settings
.
strict_draw_ordering
||
(
dst_location
==
WINED3D_LOCATION_DRAWABLE
&&
dst_texture
->
swapchain
->
front_buffer
==
dst_texture
))
gl_info
->
gl_ops
.
gl
.
p_glFlush
();
if
(
restore_rt
)
...
...
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