1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-12-12 13:08:50 +01:00
Commit Graph

658 Commits

Author SHA1 Message Date
Philip Rebohle
a078bb947e
[d3d11] Replace D3D11ShaderKey with DxvkShaderKey 2018-09-18 10:35:08 +02:00
Philip Rebohle
6c889c0005
Revert "[d3d11] Avoid unnecessary buffer slice copy when mapping buffer"
This reverts commit 72106a02cb.

Breaks things for some reason. Doesn't have much of an impact anyway.
2018-09-17 23:08:00 +02:00
Philip Rebohle
72106a02cb
[d3d11] Avoid unnecessary buffer slice copy when mapping buffer 2018-09-17 22:04:31 +02:00
Philip Rebohle
19408f0ebe
[d3d11] Fix reported RowPitch/DepthPitch for mapped buffers
Some games rely on this being the exact buffer size.
2018-09-17 07:45:05 +02:00
Philip Rebohle
f9add97a07
[d3d11] Fix Begin/End for all queries other than Event and Timestamp 2018-09-11 13:00:52 +02:00
Philip Rebohle
ea9e812798
[dxvk] Introduce new 'Created' state for queries
New initial state for queries. D3D11 returns an error when trying to
retrieve data from a query in this state, rather than S_FALSE or S_OK.
2018-09-10 23:07:51 +02:00
Philip Rebohle
d7441f274b
[dxvk] Enable device features for VK_EXT_vertex_attribute_divisor 2018-09-10 22:10:16 +02:00
Philip Rebohle
012a5c2f74
[d3d11] Add option to enforce anisotropic filtering
When setting d3d11.samplerAnisotropy to a non-negative value,
AF will be either disabled (0) or enabled with the given
anisotropy (>0) for all samplers.
2018-09-10 15:42:55 +02:00
Philip Rebohle
f8dc5612f7
[d3d11] Added option to limit tessellation factors
d3d11.maxTessFactor accepts values ranging from 8 to 64, and limits
the maximum tessellation factor accordingly.
2018-09-09 23:14:00 +02:00
Philip Rebohle
57e5b05f32
[d3d11] Fix layer count for 3D RTVs with non-zero base mip level
We have to take the mip level into account as well, or otherwise
we may create a view with more layers than the selected mip level has.
2018-09-04 07:39:46 +02:00
Philip Rebohle
09948a3495
[d3d11] Synchronize CS thread after flush when waiting for resource
In some rare cases, the flush operation itself may add new references
which we need to see while spinning on the resource's usage counter.
2018-09-01 21:25:39 +02:00
Philip Rebohle
ffc2130ee6
[d3d11] Pass format swizzle to render target views
Fixes missing caterpillars in World of Tanks (#410).
2018-09-01 18:15:31 +02:00
Philip Rebohle
66d1bed083
[d3d11] Remove old UAV counter buffer implementation 2018-08-30 15:32:46 +02:00
Philip Rebohle
5c45a50daf
[d3d11] Use D3D11CounterBuffer for UAV counters 2018-08-30 15:24:47 +02:00
Philip Rebohle
9992ba1a79
[d3d11] Add more general counter buffer allocator
We're going to need it for more than just UAV counters soon.
2018-08-30 15:24:38 +02:00
Philip Rebohle
f1b075c0f3 [dxvk] Add CS chunk pool
Reduces the number of dynamic memory allocations for CS chunks by
recycling them once they are no longer needed. Also fixes a potential
issue with chunks that are dispatched multiple times.
2018-08-27 16:07:38 +02:00
Philip Rebohle
f75e3ad13f
[d3d11] Fix silly GenerateMips bug 2018-08-16 00:57:16 +02:00
Philip Rebohle
c3c7a4172d
[d3d11] Fix interface query for ID3D11Predicate 2018-08-16 00:13:40 +02:00
Mikhail Paulyshka
2a96d717d3 [d3d11] fixed compilation with MinGW-headers 6.0.0 or greater 2018-08-15 22:02:39 +02:00
Philip Rebohle
e271bc490e
[d3d11] Enable ExtendedDoublesShaderInstructions 2018-08-15 20:12:41 +02:00
Philip Rebohle
0b1b898be4
[d3d11] Implement ID3D11DeviceContext1::ClearView
Required for Feature Level 11_1.
2018-08-15 19:03:26 +02:00
Philip Rebohle
beedd39f7d
[dxvk] Accept VkClearValue in DxvkContext::clearImageView 2018-08-15 19:03:26 +02:00
Philip Rebohle
da21a6db7f
[d3d11] Silence warning about GenerateMips being called on buffers 2018-08-15 19:03:26 +02:00
Philip Rebohle
e671692886
[d3d10] Implement D3D10Shader 2018-08-13 17:22:42 +02:00
Philip Rebohle
2af07c5faf
[d3d10] Implement D3D10Query 2018-08-13 17:22:42 +02:00
Philip Rebohle
ae12fbd23c
[d3d10] Implement D3D10CreateDepthStencilView 2018-08-13 17:22:42 +02:00
Philip Rebohle
ea46a0340e
[d3d10] Implement D3D10RenderTargetView 2018-08-13 17:22:42 +02:00
Philip Rebohle
0052ff236b
[d3d10] Implement D3D10ShaderResourceView 2018-08-13 17:22:42 +02:00
Philip Rebohle
ddb2a7bd59
[d3d10] Implement D3D10RasterizerState 2018-08-13 17:22:42 +02:00
Philip Rebohle
68bfacfcaa
[d3d10] Implement D3D10DepthStencilState 2018-08-13 17:22:41 +02:00
Philip Rebohle
f2381ac4eb
[d3d10] Implement D3D10BlendState 2018-08-13 17:22:41 +02:00
Philip Rebohle
ace06ce697
[d3d10] Implement D3D10InputLayout 2018-08-13 17:22:41 +02:00
Philip Rebohle
759ff737a4
[d3d10] Implement D3D10SamplerState 2018-08-13 17:22:41 +02:00
Philip Rebohle
553c90307a
[d3d10] Implement D3D10Buffer 2018-08-13 17:22:41 +02:00
Philip Rebohle
b97f9a702a
[d3d10] Implement D3D10 texture interfaces 2018-08-13 17:22:36 +02:00
Philip Rebohle
1e857f6342
[d3d10] Add D3D10Device stub 2018-08-13 17:22:03 +02:00
Philip Rebohle
8c1063b512
[d3d10] Add build files and implement D3D10CreateDevice functions 2018-08-13 17:22:00 +02:00
Philip Rebohle
7a28f01eca
[d3d11] Enable drawIndirectFirstInstance for FL11_0 and higher 2018-08-10 04:34:54 +02:00
Philip Rebohle
82c891b1fb
[d3d11] Fix structured buffer view validation 2018-08-10 02:39:35 +02:00
Philip Rebohle
40050e4e3f
[d3d11] Report bind flags instead of usage when view creation fails 2018-08-10 02:39:14 +02:00
Philip Rebohle
cc5219f8c0
[d3d11] Add meaningful error messages when view creation fails 2018-08-10 02:15:51 +02:00
Philip Rebohle
5276a90195
[d3d11] Add format and resource type to D3D11_COMMON_RESOURCE_DESC 2018-08-10 02:15:30 +02:00
Philip Rebohle
f9e096e954
[d3d11] Validate buffer view format compatibility
Prevents the app from creating illegal buffer views.
2018-08-09 23:37:41 +02:00
Philip Rebohle
9373bab3e3
[d3d11] Validate image view format compatibility correctly
Prevents the application from creating illegal image views.
2018-08-09 23:34:03 +02:00
Philip Rebohle
7e0a2a9165
[d3d11] Added GetBufferFormatFeatures and GetImageFormatFeatures helpers 2018-08-09 23:33:36 +02:00
Philip Rebohle
f586970c59
[d3d11] Validate buffer view bind flags 2018-08-09 22:04:03 +02:00
Philip Rebohle
b06eb4fe2a
[d3d11] Validate image view bind flags
Since the bind flags of the texture may not always match the
image usage flags of the underlying Vulkan image, we should
use the latter to check whether a view can be created.
2018-08-09 21:58:58 +02:00
Philip Rebohle
cdc85a1238
[d3d11] Add GetImageUsageFlags and GetBufferUsageFlags helpers 2018-08-09 21:49:31 +02:00
Philip Rebohle
1a4b17d607
[d3d11] Use user config to determine the maximum feature level 2018-08-09 21:08:03 +02:00
Philip Rebohle
73c91138db
[d3d11] Allow creation of SRGB textures with D3D11_BIND_UNORDERED_ACCESS
Should fix a crash in Call of Duty: Advanced Warfare.
2018-08-09 17:13:35 +02:00
Philip Rebohle
dc31be7118
[d3d11] Use global user config for D3D11 options 2018-08-07 14:59:09 +02:00
Philip Rebohle
3359b89166
[d3d11] Do not hold strong references to the ID3D11Resource in views
Emulates Windows behaviour more closely. Fixes refcount-related
error messages in Unreal Engine 4 (see #302), as well as a crash
in Yakuza 0 (see #533).
2018-08-05 21:31:13 +02:00
Philip Rebohle
ffc87faed0
[d3d11] Add private ref count helpers for ID3D11Resource 2018-08-05 21:31:13 +02:00
Philip Rebohle
c223e35608
[d3d11] Do not keep a strong reference to the swap chain back buffer
Fixes crash in Yakuza 0 with fullscreen mode enabled. SEGA, please,
stop being lazy and learn to use reference counting correctly.
2018-08-05 21:31:13 +02:00
Philip Rebohle
871c96b130
[d3d11] Refactor Unordered Access View Creation
Part 4 / 4 of the refactor.
2018-08-05 19:28:39 +02:00
Philip Rebohle
55203eb458
[d3d11] Refactor Shader Resource View Creation
Part 3 / 4 of the refactor.
2018-08-05 19:20:12 +02:00
Philip Rebohle
1038bf2ef5
[d3d11] Refactor Render Target View Creation
Part 2 / 4 of the refactor.
2018-08-05 19:07:53 +02:00
Philip Rebohle
0598982f35
[d3d11] Refactor Depth-Stencil View Creation
Part 1 of 4 of a much needed refactor. Instead of translating
the structures in the D3D11Device class, we'll move the code
to the respective view classes in order to clean up.
2018-08-05 19:02:45 +02:00
Philip Rebohle
16315a39a0
[d3d11] Use new resource helper functions during view creation
This simplifies things when both buffers and textures are allowed.
2018-08-05 18:56:42 +02:00
Philip Rebohle
b87f3f5155
[d3d11] Add common resource helper functions 2018-08-05 18:45:24 +02:00
Philip Rebohle
66e178756e
[d3d11] Introduce GetCommonBuffer helper
Also update GetCommonTexture documentation.
2018-08-05 18:29:29 +02:00
Philip Rebohle
ace8e42213
[d3d11] Move BufferInfo struct into D3D11Buffer 2018-08-05 18:24:01 +02:00
Philip Rebohle
fe66e668e5
[dxvk] Implement native discardBuffer function in the backend
This may be more efficient because it avoids renaming the buffer
in case it can be used without inserting additional barriers.
2018-08-03 11:28:00 +02:00
Philip Rebohle
fb88070888
[d3d11] Implement copy flags for CopySubresourceRegion1 / UpdateSubresource1 2018-08-03 11:22:26 +02:00
Philip Rebohle
3fee20dfec
[d3d11] Implement DiscardResource for buffers
We don't suppor this for images, and we don't support DiscardView yet.
Buffers can be invalidated, which may in some cases be beneficial in
order to avoid synchronization on the GPU.
2018-08-03 11:10:40 +02:00
Philip Rebohle
8044ce6c7e
[d3d11] Refactor UAV counter buffer allocator
- Fixes violation of the minStorageBufferOffsetAlignment limit
- Allows allocation of multiple counter buffers if necessary
2018-08-03 10:17:02 +02:00
Philip Rebohle
212bd56b93
[d3d11] Fix border color mapping for opaque white 2018-08-02 17:04:09 +02:00
Philip Rebohle
0ba00b3f59
[dxvk] Add extended device feature structure
This allows the client API to query and enable extended
features in the future, should it become necessary, much
like the extende feature queries.
2018-07-31 16:58:25 +02:00
Philip Rebohle
bf06654a83
[d3d11] Remove DXVK_SHADER_READ_PATH
Broken, and won't work with ICB UBOs.
2018-07-30 20:29:05 +02:00
Philip Rebohle
bf912d0a5f
[d3d11] Create shader constant buffer if necessary 2018-07-30 20:29:05 +02:00
Philip Rebohle
c31e646921
[dxvk] Introduce concept of shader constants
Large constant arrays should be moved to a uniform buffer instead
of being baked directly into the shader code.
2018-07-30 20:29:05 +02:00
Philip Rebohle
af5de8a8ef
[d3d11] Fix compiler warning 2018-07-30 20:27:18 +02:00
Philip Rebohle
7f0f7ac048
[d3d11] Refactor shader binding
This way we can get rid of an unnecessary template and make future
extensions possible.
2018-07-30 19:37:19 +02:00
Philip Rebohle
adadf362a3
[d3d11] Optimize WaitForResource behaviour when resource is already idle
We don't have to flush everything in this case, just flushing the current
CS chunk is enough to determine if the resource is in use by the GPU.
2018-07-23 16:08:01 +02:00
Philip Rebohle
662b6429a8
[d3d11] Refactor resource initialization
In addition to moving the code to a separate class, this also
improves flushing behaviour by limiting the amount of memory
being initialized rather than the number of commands executed.
2018-07-23 15:21:17 +02:00
Mikhail Paulyshka
f38ee85a39 [build] Fix compilation on MSVC (#505)
* [build] do not use shared_library/objects property with MSVC

* [util] use ./com/com_include.h instead of windef.h

It is required for Windows 10 SDK.

* [util] store thread procedure lambda in std::function

* [dxgi] fix annoying MSVC warning

warning C4099: 'IDXGIVkInteropDevice': type name first seen using 'class' now seen using 'struct'
2018-07-21 12:43:33 +02:00
Philip Rebohle
5fe4c4f610
[dxvk] Use VkImageViewUsageCreateInfoKHR when creating image views
Must be used when view formats are used that do not support all
usage bits of the underlying image. Refs #504.
2018-07-21 10:58:06 +02:00
Jacek Caban
88cda20746 [d3d11] Import dxgi by -l instead of directly specifying library name. 2018-07-19 08:55:34 +02:00
Jacek Caban
c934d85b85 [d3d11] Move D3D11ImmediateContext constexpr values to .cpp file
In my winelib builds, I get unresolved dxvk::D3D11ImmediateContext::MinFlushIntervalUs symbol. I'm not sure why it doesn't inline this constexpr, but it doesn't seem useful to expose that in header anyway.
2018-07-19 08:55:34 +02:00
Jacek Caban
6d16bb4c87 Don't use std::thread.
Wine needs to setup each thread that has an access to Windows APIs. It means that in winelib builds, we can't let standard C++ library create threads and need to use Wine for that instead. I wrote a thin wrapper around Windows thread functions so that the rest of code just has to use new dxvk::thread class instead of std::thread.
2018-07-19 08:55:34 +02:00
Jacek Caban
06511aa72c [build] Use .spec files instead of .def files in winelib build 2018-07-19 08:55:34 +02:00
Jacek Caban
635a43fefe [build] Explicitly specify .dll and .exe extensions in winelib build
meson can't handle that itself.
2018-07-19 08:55:34 +02:00
Philip Rebohle
2100d7aa3a
[d3d11] Fake SO support for F1 2015, Mafia 3 2018-07-12 00:32:36 +02:00
Philip Rebohle
87b5161b2a
[d3d11] Reset implicit flush timer only when actually flushing
In some situations, calling Flush without any commands that
could be flushed would unnecessarily prevent the implicit
flush heuristic from kicking in properly.
2018-07-09 20:31:54 +02:00
Philip Rebohle
c8c6f24b63
[d3d11] Fix log spam when an application uses DiscardView
We don't support this method, but we should only issue the warning
once to prevent poor performance.
2018-07-08 15:53:30 +02:00
Philip Rebohle
974db9712b
[dxvk] Remove clear rect parameter from clearRenderTarget
With deferred clears and render target-based clears, this was
not properly supported anyway.
2018-07-06 15:01:37 +02:00
Philip Rebohle
63af141383
[d3d11] Set proper view format list for typed UAVs
Typed UAVs are mutable, but we only need them to be compatible to
their typed format and the bit-compatible integer format used for
clears.
2018-07-03 13:31:22 +02:00
Philip Rebohle
cbf4772973
[d3d11] Pass image format family to the backend 2018-07-03 12:44:56 +02:00
Philip Rebohle
bc1384b7b4
[d3d11] Issue warning when using a command list more than once
The way buffers are invalidated can cause issues when the same command
list is submitted multiple times. Games don't seem to need this right
now.
2018-06-29 12:44:52 +02:00
Philip Rebohle
4520b1ca8f
[d3d11] Fix usage and access flags for multisampled images
Meta-resolve operations will use the image in a fragment shader.
2018-06-28 16:47:54 +02:00
Philip Rebohle
42a676bbdb
[d3d11] Tweak implicit flush limits
We're going to flush more often in CPU-limited scenarios, but these
new values are reasonable especially in games which submit large
amounts of GPU work at once, and should help reduce rendering latency.
Improves GPU utilization and frame rates in Hellblade by up to 10%.
2018-06-27 20:25:33 +02:00
Philip Rebohle
9fee253d09
[d3d11] Add more implicit flush points
All these methods will implicitly spill the active render pass and
are typically not called very often, so we can try to keep the GPU
busy.
2018-06-27 18:34:17 +02:00
Philip Rebohle
4f28d57352
[dxvk] Remove unused rasterizer discard state flag 2018-06-25 16:56:52 +02:00
Philip Rebohle
060cd1d87c
[d3d11] Do not use MUTABLE_FORMAT_BIT for strictly typed formats
This used to cause issues in the past, but apparently we can safely
enable this optimization now. Improves performance slightly on RADV.
2018-06-24 17:01:05 +02:00
Philip Rebohle
845c78fd20
[dxbc] Consider stream index in signature entry lookup 2018-06-23 20:13:00 +02:00
Philip Rebohle
102591369e
[dxbc] Add DxbcModuleInfo struct
This will be required in the future to pass data from the
application to the shader compiler.
2018-06-23 17:14:35 +02:00
Philip Rebohle
432708c15f
[d3d11] Fix image aspect mask for typeless resolve
The DXGI format info only stores the aspect mask for views created
with that format, but we're dealing with a raw resource here so we
have to query the aspect mask from the Vulkan format in question.
Fixes validation errors with typeless resolve if the formats of
the two involved images are identical.
2018-06-21 10:17:59 +02:00
Philip Rebohle
60bf471f06
[d3d11] Fix issue with back buffer creation
In case the window size is 0 in either dimension, we ended up
creating an image with an invalid size. Fixes Vulkan validation
errors in Hearthstone.
2018-06-21 10:12:38 +02:00
Philip Rebohle
f5d73842b2
[d3d11] Do not flush on every call to GetData
There are several scenarios when flushing can have
a significant negative impact on performance:
1. When the query result is already available
2. When the game scatters GetData calls when rendering

Frostpunk hits both issues at the same time, which led to
over 120 queue submissions per frame. This patch reduces
that to 3 submissions per frame when the game is GPU-bound.
2018-06-19 14:34:15 +02:00
Philip Rebohle
5dfe0d077d
[d3d11] Fix render target layouts for linar tiling
There currently doesn't seem to be a game which actually renders
to images with linear tiling, but we should handle this anyway.
Only the GENERAL layout is allowed if the tiling is not OPTIMAL.
2018-06-19 11:28:54 +02:00
Philip Rebohle
f519a0f2e4
[d3d11] Fake streamout support for Final Fantasy XV
The game uses this feature only for Hairworks. This hides an error
message and allows the game to start.
2018-06-16 18:52:20 +02:00
Philip Rebohle
a148233b13
[d3d11] Use clearBuffer to initialize UAV counters 2018-06-16 10:22:38 +02:00
Philip Rebohle
7fa26f1c87
[d3d11] Implement render pass spilling for UAV rendering
Spilling the render pass should make shader storage buffer/image writes
visible due to how external subpass dependencies are defined. For UAV
rendering, we need to do this when changing the UAVs, even if the render
targets themselves do not change.
2018-06-15 20:49:24 +02:00
Philip Rebohle
c93f2b980e
[d3d11] Report correct timer frequency for TIMESTAMP_DISJOINT queries 2018-06-13 14:30:44 +02:00
Philip Rebohle
dce2f844c0
[d3d11] Add ID3DUserDefinedAnnotation stub
We can implement this properly in the future using VK_EXT_debug_utils.
2018-06-11 14:29:47 +02:00
Philip Rebohle
dcd6c2c0f3
[d3d11] Implement CheckCounterInfo and related stubs
DXVK does not support device-specific counters, which seem to
be useful only for GPU profiling during development, but we
should report this properly to the application.
2018-06-11 14:01:45 +02:00
Philip Rebohle
05f24c3c38
[d3d11] Reduce log spam about UAV rendering 2018-06-10 04:19:30 +02:00
Philip Rebohle
1e7a05c796
[d3d11] Remove GetData do-not-flush workaround for Fallout 4
Not needed anymore due to the implicit flush.
2018-06-08 13:13:42 +02:00
Philip Rebohle
d4cb5115e7
[d3d11] Flush implicitly when GetData returns S_FALSE
Keeps the GPU busy when spinning on a query and ensures that we're
flushing at some point. Replaces the Fallout 4 hang workaround.
2018-06-08 13:11:24 +02:00
Philip Rebohle
a2df1ea4c9
[d3d11] Added warning that UAV rendering might not work as expected
We still haven't implemented synchronization for UAV rendering properly.
2018-06-08 12:42:09 +02:00
Philip Rebohle
c716372941
[d3d11] Move GetData implementation to D3D11ImmediateContext
It is illegal to call this method on a deferred context, so we should
filter out those calls. This allows the implementation to make use of
features specific to the immediate context.
2018-06-08 12:29:24 +02:00
Philip Rebohle
68a7ad81e1
[d3d11] Enable 64-bit math feature
We still have DMovc to implement, but it doesn't look like this
instruction is required as of now.
2018-06-07 15:35:24 +02:00
Philip Rebohle
e8ac81fe8a
[dxvk] Removed support for depth bounds test
This feature is not used in D3D11, so we don't need backend support.
2018-06-06 13:11:09 +02:00
Philip Rebohle
6579b2ad99
Merge branch 'auto-flush-v2' 2018-06-05 18:46:46 +02:00
Philip Rebohle
4a0c81276f
[d3d11] Implement new auto-flush heuristic 2018-06-04 23:31:49 +02:00
ZeroFault
d44cc7630b Allow FarCry 5 to use D3D11_MAP_FLAG_DO_NOT_WAIT (#416) 2018-06-03 22:33:08 +02:00
Philip Rebohle
fc8573891e
[d3d11] Fix vertex attribute offset with D3D11_APPEND_ALIGNED_ELEMENT
Computes the correct offset even if some vertex attributes are not used
by the vertex shader. Fixes a crash in Sleeping Dogs: Definitive Edition
(#407).
2018-05-30 13:33:48 +02:00
Philip Rebohle
c600b43d73
[d3d11] Allocate DYNAMIC buffers on device-local host-visible memory
Improves performance on AMD cards when GPU-bound.
~5% FPS increase in The Witcher 3.
2018-05-29 14:50:08 +02:00
Philip Rebohle
8cd97959f2
[d3d11] Chjeck whether input layouts are identical
Prevents redundant state changes when a game switches between
identical input layouts. Reduces the the number of Vulkan
calls in Grim Dawn by ~30%.
2018-05-27 01:10:49 +02:00
Philip Rebohle
48037a8b87
[d3d11] Enable shaderStorageImageMultisample if the device supports it 2018-05-26 20:34:40 +02:00
Philip Rebohle
b78130defd
[d3d11] Overwatch: Fake success in CreateGeometryShaderWithStreamOutput 2018-05-25 23:53:34 +02:00
Philip Rebohle
84a62f795f
Merge branch 'meta-mipgen' 2018-05-25 17:46:41 +02:00
Philip Rebohle
4b37590e14
[dxvk] Use new mip map generator 2018-05-25 17:45:41 +02:00
Philip Rebohle
49bda46a37
[d3d11] Validate and correct scissor rects
Fixes Vulkan validation errors in Frostpunk and more closely
emulates Windows behaviour.
2018-05-25 00:08:28 +02:00
Philip Rebohle
58e9280891
[dxbc] Remove Tex2D -> Tex2DArray workaround 2018-05-24 11:49:12 +02:00
Philip Rebohle
d1b705bf0d
[dxgi] Implemented IDXGISwapChain1 2018-05-23 01:06:34 +02:00
Philip Rebohle
a39b9cb131
[d3d11] Pre-clear buffers with D3D11_USAGE_DEFAULT
Some games may expect buffers, like images, to be pre-initialized.
2018-05-22 21:10:39 +02:00
Philip Rebohle
51104c104d
[d3d11] Refactor InitTexture method 2018-05-22 21:06:26 +02:00
Philip Rebohle
425a5bca2e [d3d11] Optimized buffer mapping on deferred contexts 2018-05-22 00:11:32 +02:00
Philip Rebohle
26b319b29b
[d3d11] Fallout 4: Force Flush on GetData calls 2018-05-14 02:40:59 +02:00
Philip Rebohle
c17f4e2fc0
[dxvk] Increase update buffer size
Helps reduce the number of memory allocations further
when deferred contexts are used for rendering.
2018-05-13 14:45:50 +02:00
Philip Rebohle
9d4654f445
[dxvk] Fix update buffer allocation size 2018-05-13 11:12:54 +02:00
Philip Rebohle
b6d33e6289
[d3d11] D3D11SamplerState: Cosmetic changes 2018-05-09 11:55:05 +02:00
Philip Rebohle
cd92d0b992
[dxvk] Allow binding render targets of different sizes
In order to not cause Vulkan validation issues, we have
to reduce the framebuffer size. Fixes a regression in
Bioshock Infinite.
2018-05-07 20:46:20 +02:00
Philip Rebohle
3e111086b2
[d3d11] Implement D3D11CoreCreateDevice
Some applications need this function to be present and it's better to
fail for them with an error code rather than crash because the entry
point does not exist in our DLLs.
2018-05-07 14:06:52 +02:00
Philip Rebohle
fb3dbd8bcd
[d3d11] Relaxed view format compatibility check
Fixes regressions in multiple games. MSDN docs regarding
format compatibility are wrong in every way.
2018-05-05 20:16:01 +02:00
Philip Rebohle
f4a92a685f
[d3d11] Normalize render target and depth-stencil view types
Fixes a regression in Kingdom Come: Deliverance that was
introduced in a55bee9554.
2018-05-05 15:53:49 +02:00
Philip Rebohle
5a639797d2
[d3d11] Fix stencil component mapping in shader resource views
Fixes terrain rendering in Far Cry 5.
2018-05-05 15:15:09 +02:00
Philip Rebohle
8177898151
[d3d11] Validate image view format compatibility
Fixes Vulkan validation errors in Far Cry 5.
2018-05-05 15:13:35 +02:00
Philip Rebohle
e1a27faa4a
[dxgi] Added DXGI format family info 2018-05-05 12:57:22 +02:00
Philip Rebohle
a55bee9554
[d3d11] Validate render targets before setting them up
Mimicks what native D3D11 does. Fixes validation errors in
Nier:Automata with multisampling enabled in some situations.
2018-05-05 09:12:36 +02:00
Philip Rebohle
fb288d8713
[d3d11] Disable VK_IMAGE_CREATE_MUTABLE_FORMAT_BIT for typed formats
Yields over 10% performance improvement on RADV in GPU-bound scenarios.
2018-05-05 00:49:43 +02:00
Philip Rebohle
c2c8d8be8a
[d3d11] Minor formatting fix 2018-05-04 21:52:34 +02:00
Philip Rebohle
9cec1ecca3 [d3d11] Fix stage and access mask for default constant buffers 2018-05-04 10:23:36 +02:00
Philip Rebohle
59d4f1a1fb [util] Add method to retrieve SHA1 hashes in 32-bit chunks 2018-05-03 23:47:42 +02:00
Philip Rebohle
e30a8299e6 [dxvk] Refactor DxvkFramebuffer and DxvkRenderpass 2018-05-02 00:45:10 +02:00
Philip Rebohle
41fca78d27 [dxgi] Add GetDevice method to IDXGIVkInteropSurface
Convenient way of getting the IDXGIVkInteropDevice from the surface
without having to go through several D3D interface queries.
2018-05-01 23:30:39 +02:00
Philip Rebohle
2626a26072 [d3d11] Fix sampler state validation for anisotropy
Fixes an issue where samplers are not created in Path of Exile.
2018-04-30 19:36:42 +02:00
Philip Rebohle
ba53cf92ac Revert "[dxvk] Refactor DxvkFramebuffer and DxvkRenderpass"
This reverts commit 1bbfe77013.
Breaks Path of Exile.
2018-04-30 18:47:35 +02:00
Philip Rebohle
16a25db846 Merge branch 'master' of https://github.com/doitsujin/dxvk 2018-04-30 15:56:32 +02:00