Commit 4bae47cf authored by Henri Verbeet's avatar Henri Verbeet Committed by Alexandre Julliard

wined3d: Move the swapchain logo texture blit to wined3d_cs_exec_present().

parent 84857d27
......@@ -521,13 +521,24 @@ static void wined3d_cs_exec_nop(struct wined3d_cs *cs, const void *data)
static void wined3d_cs_exec_present(struct wined3d_cs *cs, const void *data)
{
struct wined3d_texture *logo_texture, *back_buffer;
const struct wined3d_cs_present *op = data;
struct wined3d_swapchain *swapchain;
unsigned int i;
swapchain = op->swapchain;
back_buffer = swapchain->back_buffers[0];
wined3d_swapchain_set_window(swapchain, op->dst_window_override);
if ((logo_texture = swapchain->device->logo_texture))
{
RECT rect = {0, 0, logo_texture->resource.width, logo_texture->resource.height};
/* Blit the logo into the upper left corner of the back-buffer. */
wined3d_texture_blt(back_buffer, 0, &rect, logo_texture, 0,
&rect, WINED3D_BLT_SRC_CKEY, NULL, WINED3D_TEXF_POINT);
}
swapchain->swapchain_ops->swapchain_present(swapchain, &op->src_rect, &op->dst_rect, op->swap_interval, op->flags);
if (TRACE_ON(fps))
......
......@@ -469,7 +469,7 @@ static void swapchain_gl_present(struct wined3d_swapchain *swapchain,
struct wined3d_texture *back_buffer = swapchain->back_buffers[0];
const struct wined3d_fb_state *fb = &swapchain->device->cs->state.fb;
struct wined3d_rendertarget_view *dsv = fb->depth_stencil;
struct wined3d_texture *logo_texture, *cursor_texture;
struct wined3d_texture *cursor_texture;
const struct wined3d_gl_info *gl_info;
struct wined3d_context_gl *context_gl;
struct wined3d_context *context;
......@@ -488,15 +488,6 @@ static void swapchain_gl_present(struct wined3d_swapchain *swapchain,
swapchain_gl_set_swap_interval(swapchain, context_gl, swap_interval);
if ((logo_texture = swapchain->device->logo_texture))
{
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(back_buffer, 0, &rect, logo_texture, 0, &rect,
WINED3D_BLT_SRC_CKEY, NULL, WINED3D_TEXF_POINT);
}
if ((cursor_texture = swapchain->device->cursor_texture)
&& swapchain->device->bCursorVisible && !swapchain->device->hardwareCursor)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment