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
398f0d02
Commit
398f0d02
authored
Aug 04, 2016
by
Henri Verbeet
Committed by
Alexandre Julliard
Aug 04, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Use wined3d_texture_load_location() in swapchain_gl_present().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
42b90efd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
10 deletions
+8
-10
swapchain.c
dlls/wined3d/swapchain.c
+8
-10
No files found.
dlls/wined3d/swapchain.c
View file @
398f0d02
...
...
@@ -483,14 +483,14 @@ static void wined3d_swapchain_rotate(struct wined3d_swapchain *swapchain, struct
static
void
swapchain_gl_present
(
struct
wined3d_swapchain
*
swapchain
,
const
RECT
*
src_rect
,
const
RECT
*
dst_rect
,
DWORD
flags
)
{
struct
wined3d_
surface
*
back_buffer
=
swapchain
->
back_buffers
[
0
]
->
sub_resources
[
0
].
u
.
surface
;
struct
wined3d_
texture
*
back_buffer
=
swapchain
->
back_buffers
[
0
]
;
const
struct
wined3d_fb_state
*
fb
=
&
swapchain
->
device
->
fb
;
const
struct
wined3d_gl_info
*
gl_info
;
struct
wined3d_texture
*
logo_texture
;
struct
wined3d_context
*
context
;
BOOL
render_to_fbo
;
context
=
context_acquire
(
swapchain
->
device
,
back_buffer
);
context
=
context_acquire
(
swapchain
->
device
,
back_buffer
->
sub_resources
[
0
].
u
.
surface
);
if
(
!
context
->
valid
)
{
context_release
(
context
);
...
...
@@ -505,7 +505,7 @@ static void swapchain_gl_present(struct wined3d_swapchain *swapchain,
RECT
rect
=
{
0
,
0
,
logo_texture
->
resource
.
width
,
logo_texture
->
resource
.
height
};
/* Blit the logo into the upper left corner of the drawable. */
wined3d_texture_blt
(
swapchain
->
back_buffers
[
0
]
,
0
,
&
rect
,
logo_texture
,
0
,
&
rect
,
wined3d_texture_blt
(
back_buffer
,
0
,
&
rect
,
logo_texture
,
0
,
&
rect
,
WINED3D_BLT_ALPHA_TEST
,
NULL
,
WINED3D_TEXF_POINT
);
}
...
...
@@ -525,16 +525,14 @@ static void swapchain_gl_present(struct wined3d_swapchain *swapchain,
swapchain
->
device
->
cursor_texture
->
resource
.
width
,
swapchain
->
device
->
cursor_texture
->
resource
.
height
};
const
RECT
clip_rect
=
{
0
,
0
,
swapchain
->
back_buffers
[
0
]
->
resource
.
width
,
swapchain
->
back_buffers
[
0
]
->
resource
.
height
};
const
RECT
clip_rect
=
{
0
,
0
,
back_buffer
->
resource
.
width
,
back_buffer
->
resource
.
height
};
TRACE
(
"Rendering the software cursor.
\n
"
);
if
(
swapchain
->
desc
.
windowed
)
MapWindowPoints
(
NULL
,
swapchain
->
win_handle
,
(
POINT
*
)
&
dst_rect
,
2
);
if
(
wined3d_clip_blit
(
&
clip_rect
,
&
dst_rect
,
&
src_rect
))
wined3d_texture_blt
(
swapchain
->
back_buffers
[
0
]
,
0
,
&
dst_rect
,
wined3d_texture_blt
(
back_buffer
,
0
,
&
dst_rect
,
swapchain
->
device
->
cursor_texture
,
0
,
&
src_rect
,
WINED3D_BLT_ALPHA_TEST
,
NULL
,
WINED3D_TEXF_POINT
);
}
...
...
@@ -559,14 +557,14 @@ static void swapchain_gl_present(struct wined3d_swapchain *swapchain,
*/
if
(
!
swapchain
->
render_to_fbo
&&
render_to_fbo
&&
wined3d_settings
.
offscreen_rendering_mode
==
ORM_FBO
)
{
surface_load_location
(
back_buffer
,
context
,
WINED3D_LOCATION_TEXTURE_RGB
);
wined3d_texture_invalidate_location
(
back_buffer
->
container
,
0
,
WINED3D_LOCATION_DRAWABLE
);
wined3d_texture_load_location
(
back_buffer
,
0
,
context
,
WINED3D_LOCATION_TEXTURE_RGB
);
wined3d_texture_invalidate_location
(
back_buffer
,
0
,
WINED3D_LOCATION_DRAWABLE
);
swapchain
->
render_to_fbo
=
TRUE
;
swapchain_update_draw_bindings
(
swapchain
);
}
else
{
surface_load_location
(
back_buffer
,
context
,
back_buffer
->
contain
er
->
resource
.
draw_binding
);
wined3d_texture_load_location
(
back_buffer
,
0
,
context
,
back_buff
er
->
resource
.
draw_binding
);
}
if
(
swapchain
->
render_to_fbo
)
...
...
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