Commit Graph

951 Commits

Author SHA1 Message Date
Zhiyi Zhang b911e56045 wined3d: Restore display modes for all outputs when doing mode restoration.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-11-03 21:47:27 +01:00
Zhiyi Zhang 1a4f2e23c0 ddraw/tests: Test display mode restoration.
Mostly to test that when doing mode restoration, all display outputs get restored to their display
settings in the registry, not just one output gets restored.

Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-10-30 22:14:11 +01:00
Zhiyi Zhang 8915500868 ddraw/tests: Fix possible memory leaks.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-10-21 20:30:38 +02:00
Zhiyi Zhang e89c85118b ddraw/tests: Use the correct version of DirectDraw calls.
These are typos cumulated over the years.

Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-10-21 20:30:35 +02:00
Zhiyi Zhang 5ec9505a5c ddraw: Report correct frequency in GetDisplayMode().
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-09-04 21:16:49 +02:00
Zhiyi Zhang d4fdb1f62c ddraw/tests: Add display mode frequency tests.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-09-04 21:16:49 +02:00
Gabriel Ivăncescu 6179ac14cb ddraw: Return DDERR_WRONGMODE when attempting to restore surfaces of a lost device.
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-07-30 16:33:10 +02:00
Gabriel Ivăncescu 7e56c12c0f ddraw/tests: Test non-primary video memory surface in test_lost_device().
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-07-30 16:33:07 +02:00
Rémi Bernon f90d607c67 ddraw: Use the WINED3D_SWAPCHAIN_NO_WINDOW_CHANGES flag.
Signed-off-by: Gabriel Ivăncescu <gabrielopcode@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-07-07 21:18:11 +02:00
Paul Gofman 2cbab8a0a2 ddraw/tests: Port _SetSurfaceDesc() tests for mipmaps and DDSD_LPSURFACE for ddraw2.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-06-17 18:35:15 +02:00
Paul Gofman ca374dd67e ddraw/tests: Port _SetSurfaceDesc() tests for mipmaps and DDSD_LPSURFACE for ddraw4.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-06-17 18:35:13 +02:00
Paul Gofman fde4cca30b ddraw/tests: Add more tests for _SetSurfaceDesc with mipmaps.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-06-17 18:35:10 +02:00
Paul Gofman f02b0226ca wined3d: Allow setting user memory for mipmapped textures in wined3d_texture_update_desc().
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=49105
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-14 23:12:31 +02:00
Zhiyi Zhang 248b5d7427 ddraw/tests: Add get display mode tests.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-11 21:24:58 +02:00
Zhiyi Zhang 5f0608396c ddraw/tests: Test window position.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-11 21:24:58 +02:00
Zebediah Figura 616585d7fb ddraw: Implement DDENUMSURFACES_CANBECREATED.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=17233
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-05 20:53:02 +02:00
Zebediah Figura 8e8e0f48c4 ddraw: Properly compare DDENUMSURFACES_NOMATCH to TRUE.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-05 20:53:02 +02:00
Zebediah Figura 2389fae064 ddraw/tests: Add more tests for EnumSurfaces().
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-05-05 20:53:02 +02:00
Zebediah Figura b95fe88ff5 ddraw/tests: Test vtbl protection.
Signed-off-by: Zebediah Figura <zfigura@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-27 19:41:31 +02:00
Paul Gofman c24551cae8 ddraw/tests: Test system memory surface with lost device for ddraw1.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-17 19:40:21 +02:00
Paul Gofman 47e777d6ea ddraw/tests: Test system memory surface with lost device for ddraw2.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-17 19:40:19 +02:00
Paul Gofman f2ba4d78d3 ddraw/tests: Test system memory surface with lost device for ddraw4.
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-17 19:40:14 +02:00
Paul Gofman 3acc26dc22 ddraw: Check surface flags when marking surface as lost.
Fixes a regression triggered by 530a3d94de.

Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=48923
Signed-off-by: Paul Gofman <pgofman@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-17 19:40:04 +02:00
Zhiyi Zhang f91dd56ccd wined3d: Do not clip the cursor after changing display modes.
DirectDraw should clip the cursor to the primary monitor only when the
cooperative level is DDSCL_EXCLUSIVE. For Direct3D 8, 9 and DXGI,
changing display modes shouldn't clip the cursor as tests showed.

Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-09 21:04:04 +02:00
Zhiyi Zhang 5a2e6f5e58 ddraw/tests: Test cursor clipping.
Signed-off-by: Zhiyi Zhang <zzhang@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-09 21:04:04 +02:00
Akihiro Sagawa 62e13708d0 ddraw: Allow to create managed textures with DDSCAPS_TEXTURE|DDSCAPS_3DDEVICE caps.
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=48844
Signed-off-by: Akihiro Sagawa <sagawa.aki@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-02 12:56:37 +02:00
Akihiro Sagawa 8bb3ebced4 ddraw/tests: Add more managed texture tests.
Signed-off-by: Akihiro Sagawa <sagawa.aki@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-04-02 12:56:32 +02:00
Chip Davis d5f25c2cd7 ddraw/tests: Introduce compare_uint().
Analogous to compare_float().

Signed-off-by: Chip Davis <cdavis@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-03-30 23:10:07 +02:00
Paul Gofman 792dc34978 ddraw/tests: Test locking lost surface for ddraw1.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-03-26 18:34:50 +01:00
Paul Gofman 98b8f680b1 ddraw/tests: Test locking lost surface for ddraw2.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-03-26 18:34:50 +01:00
Paul Gofman d79f5a2a9f ddraw/tests: Test locking lost surface for ddraw4.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-03-26 18:34:50 +01:00
Paul Gofman 530a3d94de ddraw: Deny locking lost surfaces.
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-03-26 18:34:50 +01:00
Stefan Dösinger d6917dee9d ddraw/tests: Don't print uninitialized l in test_compressed_surface_stretch.
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>
2020-03-16 21:31:46 +01:00
Stefan Dösinger bc4ad3ca4d ddraw/tests: Re-init for every test_surface_discard iteration.
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>
2020-03-16 21:31:37 +01:00
Stefan Dösinger 843e8e0726 ddraw/tests: WARP returns SURFACELOST when flipping a surface in normal mode.
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>
2020-02-17 15:06:19 +01:00
Stefan Dösinger 885f5bf04f ddraw/tests: P8 -> RGB blits are broken on WARP 1709 and newer.
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>
2020-02-17 15:06:17 +01:00
Stefan Dösinger 36012feb6d ddraw/tests: Clear the DXT3 destination surface manually.
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>
2020-02-17 15:06:14 +01:00
Stefan Dösinger 30cbc4a829 ddraw/test: Completely disable the refcount stealing GetClipper call.
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>
2020-02-06 21:40:22 +01:00
Sven Baars 7aa9d6970c ddraw/tests: Reverse cleanup order in test_coop_level_threaded().
Signed-off-by: Sven Baars <sbaars@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-02-06 21:40:22 +01:00
Stefan Dösinger 5a93d97268 ddraw/tests: Init the lock desc before using it.
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>
2020-01-28 14:22:17 +01:00
Stefan Dösinger 49451663d6 ddraw/tests: R200 rejects some bad draw calls.
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>
2020-01-28 14:22:14 +01:00
Stefan Dösinger b5ddcf4126 ddraw/tests: Changing only viewport Z range is broken on r500 on Win10.
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>
2020-01-28 14:22:12 +01:00
Stefan Dösinger 0a8d7b533c ddraw/tests: Dx9 and earlier cards have problems with HW blits to R5G5B5A1.
My Geforce 7 sends R5G6B5 data to the R5G5B5A1 surface without any
conversion. r200 and r500 set the alpha bit on the destination. This
applies to sysmem->vidmem and vidmem->vidmem blits.

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>
2020-01-28 14:22:08 +01:00
Jacek Caban e7a2e45c70 ddraw/tests: Don't use log2f to avoid mingwex dependency.
Signed-off-by: Jacek Caban <jacek@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
2020-01-24 18:22:43 +01:00
Stefan Dösinger 97ee54e9d6 ddraw/tests: Don't rely on the implicit vertex color in test_viewport.
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>
2020-01-24 17:21:07 +01:00
Stefan Dösinger a86798200a ddraw/tests: Don't COLORFILL a surface with a clipper.
The r500 driver on Windows 10 fails the call with DDERR_EXCEPTION. I believe
this problem is new on Windows 10, I don't remember seeing it on Win7 on the
same hardware. It is probably a side effect of running Win10 with the Win7
driver.

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>
2020-01-24 17:21:07 +01:00
Stefan Dösinger b6904bb618 ddraw/tests: WinXP drivers don't necessarily set dib.dsBm.bmBits.
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>
2020-01-24 17:21:07 +01:00
Stefan Dösinger ad279073c6 ddraw/tests: The Windows XP r200 driver does not report DDSCAPS_OWNDC.
Creating a surface with this flag set behaves in the same way as it does
on newer hardware that sets the flag - it succeeds for sysmem surfaces
and fails with E_NOTIMPL for vidmem ones.

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>
2020-01-24 17:21:07 +01:00
Stefan Dösinger ed33ddd452 ddraw/tests: Don't leak overlay if DWM cannot be disabled.
This fixes test_caps on my GeForce 650M Windows 10 machine.

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>
2020-01-24 17:21:07 +01:00
Stefan Dösinger d82a2683b1 ddraw/tests: Mark a Geforce 9600 misbehavior broken().
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>
2020-01-22 09:20:25 +01:00