Commit Graph

365 Commits

Author SHA1 Message Date
Michael Stefaniuc bb82e915d1 wined3d: Use SetRect() instead of open coding it.
Signed-off-by: Michael Stefaniuc <mstefani@redhat.de>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-07-03 10:17:57 +09:00
Henri Verbeet 8ae3a9b624 wined3d: Introduce a helper function to allocate arrays.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-05-24 16:19:01 +09:00
Stefan Dösinger aa475ce23f wined3d: Discard the backbuffer in swapchain_gl_present() with the "discard" swap effect.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-05-18 01:06:17 +09:00
Henri Verbeet 3b96ac290d wined3d: Allocate system memory for complete textures.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-21 14:09:39 +09:00
Henri Verbeet 62a766f75c wined3d: Use the texture dimensions in swapchain_blit().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-20 14:02:38 +09:00
Henri Verbeet feb86895b4 wined3d: Store renderbuffer IDs in struct wined3d_texture.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-19 14:56:02 +09:00
Henri Verbeet 4896cda6c5 wined3d: Track SFLAG_DISCARD per-texture.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-15 12:32:32 +09:00
Henri Verbeet 82a7f1ebf2 wined3d: Implement texture DC creation on top of D3DKMTCreateDCFromMemory().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-15 12:32:25 +09:00
Henri Verbeet 64767de277 wined3d: Use the texture dimensions in swapchain_gdi_frontbuffer_updated().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-14 13:13:39 +09:00
Henri Verbeet 2a2554ee59 wined3d: Store sub-resource map counts in the sub-resource structure.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-11 11:36:04 +09:00
Henri Verbeet e6e89dbc65 wined3d: Avoid surface_from_resource() in swapchain_gdi_present().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-05 12:52:24 +09:00
Henri Verbeet 6b8fb1c22e wined3d: Also update the swap interval when not recreating the context in wined3d_device_reset().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-05 12:52:19 +09:00
Henri Verbeet e50ff74808 wined3d: Avoid surface_from_resource() in swapchain_gdi_frontbuffer_updated().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-01 12:48:39 +09:00
Henri Verbeet c633ffb95c wined3d: Avoid surface_from_resource() in swapchain_gl_present().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-04-01 12:48:37 +09:00
Stefan Dösinger 984934f685 wined3d: Introduce wined3d_texture_invalidate_location().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-31 10:40:07 +09:00
Stefan Dösinger 5a29cc8787 wined3d: Introduce wined3d_texture_validate_location().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-30 11:54:23 +09:00
Henri Verbeet 5f05acfcff wined3d: Use wined3d_texture_blt() in swapchain_gl_present().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-30 11:54:11 +09:00
Stefan Dösinger 5e27e6b5d8 wined3d: Store sub-resource locations in the sub-resource structure.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-29 10:39:31 +09:00
Henri Verbeet 491e88efa5 wined3d: Get resource info from the texture in swapchain_blit().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-29 10:39:22 +09:00
Henri Verbeet a36c7e6bda wined3d: Use wined3d_texture_blt() in wined3d_swapchain_get_front_buffer_data().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-26 12:07:29 +09:00
Henri Verbeet 7bf2a34528 wined3d: Pass a texture instead of a surface to context_create().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-24 11:51:01 +09:00
Henri Verbeet a2e5881de1 wined3d: Handle NULL rectangles in wined3d_swapchain_present().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-18 12:20:52 +09:00
Henri Verbeet 240912c59b wined3d: Ignore the dirty region for swapchain presents more explicitly.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-18 12:20:49 +09:00
Henri Verbeet 91f0b00103 wined3d: Allow swapchain sample counts to be overridden with a registry key.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-16 12:09:55 +09:00
Michael Stefaniuc b3790bf803 wined3d: Use SetRect() instead of open coding it.
Signed-off-by: Michael Stefaniuc <mstefani@redhat.de>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-09 18:39:40 +09:00
Henri Verbeet c059191e0f wined3d: Avoid surface_from_resource() in swapchain_gl_frontbuffer_updated().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-03 13:00:47 +09:00
Stefan Dösinger a7316e1927 wined3d: Get rid of wined3d_surface_ops.surface_unmap().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-02 12:08:21 +09:00
Stefan Dösinger d71f452c4d wined3d: Rotate through swapchain buffers.
Signed-off-by: Stefan Dösinger <stefandoesinger@gmx.at>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-03-01 01:50:12 +09:00
Ken Thomases 52a99f2ead wined3d: Change calls of GetDC() to GetDCEx() with DCX_CACHE so the HDC is not shared with other threads.
Windows created by the app may use the CS_CLASSDC or CS_OWNDC class styles.  In
that case, GetDC() would return the same HDC to all callers.  It's not safe,
though, for multiple threads to use the same HDC without synchronization.  The
app may be using that HDC from multiple threads and using some synchronization
scheme to make that safe, but wined3d is not able to cooperate in such a scheme.

Using GetDCEx() with DCX_CACHE ensures that wined3d gets an independent HDC.

Signed-off-by: Ken Thomases <ken@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-16 23:26:31 +09:00
Henri Verbeet 0b6b5176cc wined3d: Get rid of unused/unimplemented WINEDDBLT_* flags.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-02-16 12:09:37 +09:00
Henri Verbeet dafaae7730 wined3d: Unify WINED3D_RTYPE_TEXTURE and WINED3D_RTYPE_CUBE_TEXTURE.
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2016-01-27 12:38:46 +09:00
Stefan Dösinger bcabae6f40 wined3d: Clip software cursor blits.
This prevents the SW cursor from disappearing when it is at the edge of
the screen.

Signed-off-by: Stefan Dösinger <stefandoesinger@gmx.at>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-12-12 05:27:11 +01:00
Riccardo Bortolato e15e2569a8 wined3d: Call wined3d_texture_decref() instead of wined3d_surface_decref() in swapchain_gl_present().
Signed-off-by: Riccardo Bortolato <rikyz619@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-11-06 14:46:13 +09:00
Riccardo Bortolato 53f795af0a wined3d: Make wined3d_swapchain_get_front_buffer_data work with wined3d_texture and sub_resource_idx.
Signed-off-by: Riccardo Bortolato <rikyz619@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-10-20 00:30:38 +09:00
Stefan Dösinger 973de3f59c wined3d: Pass a context to surface_load_location.
Signed-off-by: Stefan Dösinger <stefan@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2015-10-16 19:56:42 +09:00
Stefan Dösinger ebd6bf7f7a wined3d: Remove old surface flipping hacks.
They're non-functional these days anyway.
2015-09-08 21:59:16 +09:00
Stefan Dösinger 2936e4ac54 wined3d: Remove wined3d_backbuffer_type. 2015-09-08 21:59:16 +09:00
Stefan Dösinger fa0041954f wined3d: Return a texture from the swapchain resource creation callback. 2015-09-04 20:01:05 +09:00
Stefan Dösinger f010e5d88a wined3d: Return a texture from wined3d_swapchain_get_back_buffer. 2015-09-03 21:11:07 +09:00
Stefan Dösinger c4e4647ca5 d3d9: Validate swap effect and backbuffer count. 2015-08-27 21:43:46 +09:00
Henri Verbeet fca2d19423 dxgi: Implement dxgi_swapchain_ResizeBuffers(). 2015-08-07 23:44:19 +09:00
Henri Verbeet 2735947d76 wined3d: Introduce a separate function to resize swapchain buffers. 2015-08-07 23:44:14 +09:00
Matteo Bruni 6521fc78be wined3d: Use the correct texture coordinates in swapchain_blit() in the non-glBlitFramebuffer, NP2 case. 2015-07-09 17:18:22 +09:00
Stefan Dösinger 2d56694445 wined3d: Implement color keying in arbfp_blit. 2015-04-10 21:43:12 +09:00
Stefan Dösinger 19c860499a wined3d: Filter messages generated by focus handling. 2014-12-08 14:18:43 +01:00
Stefan Dösinger f103247ddf wined3d: Add a comment about reset during focus change. 2014-12-02 13:05:54 +01:00
Stefan Dösinger f4d520d6e2 wined3d: Don't minimize hidden windows. 2014-11-20 22:31:26 +09:00
Stefan Dösinger 09a91231a6 wined3d: Set the device window size on focus window activation. 2014-11-20 22:31:13 +09:00
Stefan Dösinger f6dde70624 wined3d: Restore the display mode on focus change. 2014-11-19 17:56:44 +09:00
Stefan Dösinger 45d530461b wined3d: Minimize device windows on focus loss. 2014-11-17 17:36:12 +09:00