Philip Rebohle
905d69e77b
[d3d9] Don't pass format mapping to D3D9CommonTexture
...
Instead, infer it from the format. This is basically being done
already, however the mapping we pass in is not correct if the
image format is Unknown.
2020-01-17 17:47:08 +01:00
Philip Rebohle
7150d2b7fb
[dxvk] Don't enable VK_KHR_descriptor_update_template
...
Core in Vulkan 1.1.
2020-01-17 17:46:59 +01:00
Philip Rebohle
4923bc20f7
[dxvk] Don't enable VK_KHR_shader_draw_parameters
...
Core in Vulkan 1.1.
2020-01-17 17:46:59 +01:00
Philip Rebohle
073669b7e7
[dxvk] Don't enable VK_KHR_maintenance1, VK_KHR_maintenance2
...
Core in Vulkan 1.1.
2020-01-17 17:46:59 +01:00
Philip Rebohle
60145f0167
[dxvk] Don't enable VK_KHR_dedicated_allocation, VK_KHR_get_memory_requirements2
...
Core in Vulkan 1.1.
2020-01-17 17:46:59 +01:00
Philip Rebohle
252ec9406d
[dxvk] Don't enable VK_KHR_get_physical_device_properties2
...
Core in Vulkan 1.1.
2020-01-17 17:46:59 +01:00
Philip Rebohle
6690a31d8d
[dxbc] Don't enable SPV_KHR_shader_draw_parameters
...
Core in SPIR-V 1.3.
2020-01-17 17:46:59 +01:00
Philip Rebohle
7e35a0687b
[d3d9] Don't enable DrawParameters capability
...
Not used in D3D9 shaders.
2020-01-17 17:46:59 +01:00
Shmerl
238fcad055
Readability cleanup
2020-01-17 12:31:52 +01:00
Shmerl
0e5b5763f0
Use verbose file operations during installation
2020-01-17 12:31:52 +01:00
Shmerl
b08a9e5acf
Add installation support for pure 64-bit Wine (non WoW64)
2020-01-17 12:31:52 +01:00
Joshua Ashton
b954ab886f
[d3d9] Implement GetFrontBufferData (currently with first backbuffer)
...
Fixes screenshots in ATi ToyShop demo
2020-01-17 06:01:48 +00:00
Joshua Ashton
e5df573292
[d3d9] Add AreFormatsSimilar helper
2020-01-17 05:55:47 +00:00
Joshua Ashton
9fce945b62
[d3d9] Don't create views if we are a null resource
2020-01-17 04:20:05 +00:00
Philip Rebohle
bafcaa0c07
[dxvk] don't try to fall back to Vulkan 1.0
...
Vulkan 1.1 came out in early 2018, everyone should be using a
compatible driver and ICD loader these days.
2020-01-16 19:48:10 +01:00
Philip Rebohle
eb37dfa8d2
[d3d9] Create multiple back buffers for GetBackBuffer API
...
Needed by Atelier Sophie.
2020-01-16 18:50:23 +01:00
Philip Rebohle
c911784bb8
[d3d9] Synchronize with presentation in D3D9SwapChainEx::Reset
...
Otherwise, the subsequent patches would break if Reset is called
while there's still a frame in flight.
2020-01-16 18:50:23 +01:00
Philip Rebohle
41a91cbae6
[dxvk] Implement image swapping
2020-01-16 18:50:23 +01:00
Philip Rebohle
5193e8ef24
[dxvk] Introduce DxvkPhysicalImage
2020-01-16 18:50:23 +01:00
Philip Rebohle
2c457e496a
[dxvk] Register image views with the parent image
...
Needed for image renaming.
2020-01-16 18:50:23 +01:00
Philip Rebohle
8770a14743
[dxvk] Use small_vector to store image view format compatibility list
...
Avoids some memory allocations, but increases the object size slightly.
2020-01-16 18:50:23 +01:00
Philip Rebohle
70e52aa6f2
[dxvk] Factor out image view creation
2020-01-16 18:50:23 +01:00
Philip Rebohle
e4215252df
[util] Add small_vector helper
...
A vector with a small fixed-size array, which changes to a dynamic
array as needed. Can be used to avoid memory allocations in some
scenarios.
2020-01-16 18:50:23 +01:00
Andrew Eikum
5706ec55e4
[dxgi] Don't check window validity in IDXGISwapchain::GetFullscreenState
...
This causes an error on exit in Jump King, which uses SharpDX.
2020-01-16 17:50:32 +01:00
Joshua Ashton
9e5e4c1cfc
[d3d9] Don't mark for hazards if we aren't rendering to mip 0
2020-01-16 03:04:58 +00:00
Joshua Ashton
7c53a997ef
[d3d9] Keep subresource views in subresources, defer creation until needed
...
Avoid creating a bunch of views that we probably don't need whenever a texture is created
2020-01-16 03:00:31 +00:00
Philip Rebohle
18450f4643
[d3d11] Lock immediate context when submitting presentation commands
...
Otherwise, a race condition occurs if a game submits rendering commands
at the same time as presenting the swap chain image. Only works if
multithreaded protection is enabled, but according to MSDN, it is
illegal to use DXGI commands and the immediate context in parallel.
Fixes stability issues in Tales of Vesperia.
2020-01-15 23:48:58 +01:00
Joshua Ashton
a7b4c29957
[dxso] Use m's id for bump matrix in TexBem
...
Fixes refractive windows in Vampire The Masquerade: Bloodlines
Was also a silly typo given my comment right above about it 🐸 !
2020-01-15 18:04:04 +00:00
Joshua Ashton
64ece36349
[d3d9] Implement d3d9.forceSwapchainMSAA
...
Works good enough for some titles like Vampire The Masquerade: Bloodlines.
2020-01-11 02:34:37 +00:00
Joshua Ashton
3ebd4b28a3
[d3d9] Defer dialog mode swapchain recreation decision to Present
...
Avoids unnecessary swapchain recreations if the game calls SetDialogBoxMode multiple times per frame
2020-01-10 04:30:55 +00:00
Joshua Ashton
9647e449d2
[d3d9] Remove redundant logging from SetDialogBoxMode
...
This path doesn't error anyway...
2020-01-10 04:30:02 +00:00
Philip Rebohle
4308d9b4b3
[meta] Release 1.5.1
2020-01-09 20:10:58 +01:00
Philip Rebohle
79fcaa9fba
[d3d9] Remove unused variable from D3D9DeviceEx::Clear
...
Fixes a compiler warning.
2020-01-09 18:06:58 +00:00
Philip Rebohle
cd00719122
[dxvk] Tweak number of pipeline compiler threads
...
Gives some 6-core and 8-core CPUs a bit more breathing room, while
also supporting up to 32 workers instead of just 16 to leverage
the new high core count Ryzen CPUs.
2020-01-09 18:04:25 +01:00
Joshua Ashton
47555f1dda
[d3d9] Add GetSurfaceExtent helper
2020-01-09 03:29:58 +00:00
Joshua Ashton
cd58b147a1
[d3d9] Respect mip != 0 for Clear fastpath
2020-01-09 03:24:50 +00:00
Joshua Ashton
ebcab68822
[d3d9] Respect specific mip size for implicit viewport in SetRenderTarget
...
Closes #1295
2020-01-09 03:19:37 +00:00
Joshua Ashton
3cfc16ea34
[d3d11] Move shader stage and buffer slot calc to inside lambda
...
Take advantage of the fact that template permutations transfer into lambdas inside of them.
Removes some unnecessary captures.
2020-01-08 23:09:53 +01:00
Joshua Ashton
b738c4220b
[d3d9] Scale depth bias value based on current format's r
value
2020-01-08 19:38:18 +00:00
Joshua Ashton
2d7f4b1a2c
[d3d9] Set depth bias values separately, optimize redundant rasterizer state changes
2020-01-08 19:38:18 +00:00
Philip Rebohle
b376417f20
[dxvk] Fix loading vkAcquireFullScreenExclusiveModeEXT etc.
...
We're not using those functions, but these are device functions, not
instance functions. vkGetPhysicalDeviceSurfacePresentModes2EXT appears
to be an instance function.
Found while investigating #1324 .
2020-01-08 04:10:10 +01:00
Philip Rebohle
8b9c03ce76
[util] Improve Spinlock implementation
...
Addresses two potential issues:
- Our spinlocks are almost never contested, however the code generated
is not ideal without the likely/unlikely hints.
- In the unlike event that a spinlock is in fact contested, we'd yield
immediately, even though most of the time we'd only have to wait for
a few hundred cycles at most.
Replacing our spinlocks with std::mutex is not an option due to much
higher locking overhead in the uncontested case; doing so reduces
performance significantly for the buffer slice and pipeline locks.
2020-01-07 17:28:33 +01:00
Joshua Ashton
9541aef0b8
[d3d9] Ensure D3DDISPLAYMODEEX we use to call the Ex funcs has its size set correctly
2020-01-06 04:14:02 +00:00
Joshua Ashton
61b6f8f297
[d3d9] Hook up GetAdapterDisplayMode to resp. adapter func
...
Fixes fullscreen at < native res in Vampire: The Masquerade Bloodlines 1/2
2020-01-06 04:07:02 +00:00
Joshua Ashton
91574993df
[d3d9] Return current display mode in GetAdapterDisplayModeEx rather than last mode
...
Fixes fullscreen at < native res in Vampire: The Masquerade Bloodlines 1/2
2020-01-06 04:06:45 +00:00
Joshua Ashton
845ab2b5af
[d3d9] Don't re-set dialogbox mode on swapchain Reset
...
There's no reason to do this now that we have no error path in SetDialogBoxMode...
2020-01-04 21:12:53 +00:00
Joshua Ashton
d53b3adaea
[d3d9] Remove incorrect error returns SetDialogBoxMode
...
The Microsoft docs for this are incorrect based on my tests of all the described edge-cases.
https://docs.microsoft.com/en-us/windows/win32/api/d3d9/nf-d3d9-idirect3ddevice9-setdialogboxmode
2020-01-04 21:10:26 +00:00
Philip Rebohle
ae01bd8bd4
[dxgi] Ignore sync interval if PRESENT_TEST is used
...
Otherwise, the following sequence leads to the Vulkan
swap chain being recreated once per frame:
swapchain->Present(0, DXGI_PRESENT_TEST);
swapchain->Present(1, 0);
Found while investigating #1314 .
2020-01-04 11:18:51 +01:00
Philip Rebohle
3db00a0f40
[d3d11] Increment transfer command counter when initializing UAV counter
...
Otherwise, we won't clear the counter before it is being used if there are
no other transfer commands recorded to the initializer command buffer.
2020-01-03 13:44:23 +01:00
Joshua Ashton
0343938c2e
[util] Enable d3d9.forceSamplerTypeSpecConstants for Halo [CE]
...
The game uses incorrect sampler types in the shaders for glass rendering which breaks it on native + us if we don't spec-constantly chose the sampler type automagically.
2020-01-01 20:58:42 +00:00