Commit Graph
9567 Commits
Author SHA1 Message Date
Henrik Rydgård c1d32e8b3e D3D11: Better set current texture to null first, otherwise we can run into another issue. 2020-05-10 23:42:52 +02:00
Henrik Rydgård f708396bda Fix a comment 2020-05-10 23:10:57 +02:00
Henrik Rydgård 73c253e2ac D3D11: Fix a bind ordering issue in depal (only a problem with debug layer enabled) 2020-05-10 23:10:57 +02:00
Unknown W. Brackets ba566ef26a GPU: Minor lighting cleanup in software transform.
In this case, unlitColor is already materialAmbient.
2020-05-08 23:09:24 -07:00
Unknown W. Brackets ef43ec5f33 GPU: Split up software transform into phases. 2020-05-08 23:09:24 -07:00
Henrik RydgårdandGitHub bf6357a53a Merge pull request #12875 from unknownbrackets/gpu-bof
GLES: Simplify the framebuf offset detection
2020-05-08 23:03:07 +02:00
Unknown W. Brackets b413a58945 GLES: Add safety handling for offset depal.
Just in case...
2020-05-07 23:30:17 -07:00
Unknown W. Brackets 16e47f6333 GPU: Calc framebuf offset with right params.
It has nothing to do with the target or source framebuf, oops.
2020-05-07 23:22:51 -07:00
Unknown W. Brackets 4d11256807 GPU: Avoid a texture offset change in sw transform.
If we do it this late, it changes the shader, but that is tricky to handle
for all the backends.
2020-05-07 23:18:51 -07:00
Unknown W. Brackets 48980d8786 GLES: Simplify the framebuf offset detection.
It's clearly not been understood well as changes were made, so let's dump
a bunch of comments on it.
2020-05-07 23:12:14 -07:00
Henrik Rydgård f9f568d266 Vulkan: Framebuffer manager: Use an allocator for "MakePixelTexture" images.
Fixes #12355 (or at a minimum, will improve it).
2020-05-06 22:24:10 +02:00
Henrik Rydgård 5508bfb596 Vulkan: Discard negative width/height framebuffer blits. Will likely help #12531. 2020-04-26 12:44:11 +02:00
Henrik RydgårdandGitHub 5fbe369fd0 Merge pull request #12836 from unknownbrackets/d3d-depth
D3D11: Always use accurate depth
2020-04-19 14:02:50 +02:00
Unknown W. Brackets 4ea5d165f5 D3D11: Always use accurate depth.
The Direct3D APIs use a "min" and "max" value, and it's required that min
must be less than or equal to max.  If this requirement is not met, the
viewport parameters are not updated.

We forced accurate depth on for NVIDIA and AMD, but this just meant Intel
was still broken and less people were reporting bugs about it.

Although the PSP GE has depth viewport transform, this is not used for
clipping and is not actually the depth range.  The minz and maxz GE
registers are the depth range, and minz must be less than or equal to maxz
for drawing to occur.
2020-04-18 22:34:33 -07:00
Henrik RydgårdandGitHub c6cd45e933 Merge pull request #12813 from unknownbrackets/gles-state
GLES: Update shader uniforms after apply state
2020-04-12 15:21:23 +02:00
Henrik RydgårdandGitHub 037d89906b Merge pull request #12814 from unknownbrackets/debugger
GE Debugger: Prevent crash when stopping dump execution
2020-04-12 15:20:19 +02:00
Unknown W. Brackets 3b74d4b680 GE Debugger: Prevent crash when stopping execution. 2020-04-11 23:44:31 -07:00
Unknown W. Brackets b57ba89b45 GLES: Update shader uniforms after apply state.
We may set shaderblend, projmatrix, or depthrange dirty in
ApplyDrawState().  These need to update shader uniforms to apply
correctly, but we were checking beforehand.
2020-04-11 17:40:39 -07:00
Unknown W. Brackets a5ede2bed3 GLES: Re-enable non-float depal shader path.
Was accidentally always detected as unsupported.
2020-04-07 22:49:07 -07:00
Unknown W. Brackets ac60e2ecd4 GPU: Track HW tess at start of frame too.
This also makes it so we don't force the setting off when you change
backends, and just ignore it if unsupported.
2020-04-04 11:52:32 -07:00
Unknown W. Brackets 46b9454e73 GPU: Reset hw transform once per frame.
Might prevent potential crashes if it changes mid-frame.
2020-04-04 11:21:22 -07:00
Unknown W. Brackets 30ede8240c GPU: Move hw transform decision to draw engine. 2020-04-04 11:14:32 -07:00
Unknown W. Brackets c42fb72419 GPU: Update uniforms w/ consistent render mode too. 2020-04-04 11:03:07 -07:00
Unknown W. Brackets ad98609819 GPU: Use consistent buffered rendering state.
The setting can be changed in Qt and Windows between frames, so let's
track the current setting in most places.  This is everywhere fbman is
easily accessible.
2020-04-04 10:51:47 -07:00
Henrik Rydgård 21eaef04fc Vulkan: Pick shaders after calling ConvertStateToVulkanKey because it may end up disabling shader blending
(due to too many copies, see DrawEngineCommon::ApplyShaderBlending).

(So much state leaking all over the place ... I want to redesign the
whole thing).

Typo fix in comment
2020-03-29 15:02:40 +02:00
Unknown W. Brackets 4a0109d273 GPU: Treat negative light exp same as 0.
Based on #12507 and some tests, seems like negative exponents are also
fixed to a 1.0f result.
2020-03-22 22:28:05 -07:00
Unknown W. Brackets a95f3111cf GPU: Assume a scissor of 481x273 is a mistake.
We already do this for viewport, and only when region is still a correct
size.  Helps flicker in Everybody's Golf.
2020-03-21 23:47:50 -07:00
Unknown W. Brackets 4a8839c99d GPU: Avoid divide by zero in garbage displaylist. 2020-03-19 20:56:24 -07:00
Unknown W. Brackets c7a27ed9af GPU: Fix memory corruption with bufw > w.
Seen for example in Mecho Wars.
2020-03-19 20:56:02 -07:00
Henrik RydgårdandGitHub 01165e7277 Merge pull request #12699 from unknownbrackets/softgpu-minor
softgpu: Correct clear/solid rect BR corner
2020-03-10 07:34:15 +01:00
Unknown W. Brackets f1dfb25427 softgpu: Correct clear/solid rect BR corner.
The scissor is inclusive, not exclusive.
2020-03-09 18:57:55 -07:00
Henrik Rydgård a19ba6d472 New heuristic for getting rid of unnecessary "antialias-lines".
Should fix #12558, while keeping the other aa line issues also fixed.

Heuristic derived from discussions in #12558 and #6483.
2020-03-10 00:49:16 +01:00
Henrik Rydgård 2eaa1db046 Vulkan: Track down another one of those minor resource leaks.
Also no need to zero, queue for delete does it already.
2020-03-09 00:48:00 +01:00
Unknown W. Brackets ac909d2192 Vulkan: Ensure scaling happens in cached RAM.
There's a non-trivial performance impact to using uncached coherent
memory, which is usually what we get for the push buffer.
2020-03-08 12:02:46 -07:00
Unknown W. Brackets 3ce9483d24 Headless: Prevent crash running graphics tests. 2020-03-08 11:10:16 -07:00
Henrik Rydgård f8a0ba3b86 Update the glslang submodule, fix the build afterwards. 2020-03-03 22:19:32 +01:00
Unknown W. Brackets 051a84e9bd GPU: Restart when changing inflight frames setting.
We need to keep the push and pull in step, so changing at runtime is
messy.
2020-03-02 19:21:15 -08:00
Henrik RydgårdandGitHub fa8968f5c6 Merge pull request #12660 from unknownbrackets/frame-latency
GPU: Add setting to control inflight frame usage
2020-03-02 00:16:48 +01:00
Henrik RydgårdandGitHub c363c16af9 Merge pull request #12665 from unknownbrackets/frameskip
GPU: Use old frame when presenting a skip
2020-03-01 23:35:01 +01:00
Unknown W. Brackets cebcfb1bbd GPU: Use old frame when presenting a skip.
If we flip using a skipped frame, we may show an even older frame causing
weird flickering.
2020-03-01 13:55:28 -08:00
Henrik Rydgård 63f06cdd91 Address some feedback, thanks unknown 2020-03-01 18:41:09 +01:00
Unknown W. Brackets 98df4bbec3 GPU: Allow choosing number of inflight frames. 2020-03-01 08:53:46 -08:00
Unknown W. Brackets a91e206926 GPU: Add setting to control inflight frame usage. 2020-03-01 06:21:27 -08:00
Henrik Rydgård 25dcf8dd8d Warning fixes 2020-03-01 14:15:10 +01:00
Henrik Rydgård 0da04f3694 Vulkan: Support devices that don't properly support 16-bit texture (like MoltenVK).
Fixes #12615.

Will make finishing #10654 worthwhile.
2020-03-01 14:07:13 +01:00
Henrik RydgårdandGitHub 2ec82951a0 Merge pull request #12659 from unknownbrackets/vsync
Support vsync in all hardware backends, support runtime update
2020-03-01 09:52:14 +01:00
Unknown W. Brackets 3c1e8abcfe GPU: Centralize vsync interval logic.
We already do unthrottle checking here.
2020-02-29 22:27:00 -08:00
Henrik Rydgård 974095ac10 Log shader contents to VERBOSE instead of DEBUG. 2020-02-29 10:46:04 +01:00
Unknown W. Brackets 5009698cc0 Core: Use a shared_ptr for i18n categories.
This does not make them thread safe, but it reduces the chances of a crash
a bit (see #12594.)
2020-02-09 07:35:16 -08:00
Henrik Rydgård 41a6b97023 DX9: Simplify some expressions 2020-01-26 16:34:46 +01:00