Commit Graph
9567 Commits
Author SHA1 Message Date
Henrik Rydgård cafce7365b Vulkan: Fix frame ordering issue with postprocessing shaders
Requested an init command buffer outside the frame, which is dangerous
and caused validation problems with command pool resets.

Would like to assert on insideFrame in GetInitCmd, but we use it from
some init code where it does work correctly. Might clean that up at some
point.
2022-10-21 12:52:21 +02:00
Henrik RydgårdandGitHub a830f18054 Merge pull request #16265 from unknownbrackets/lighting-nonormal
GPU: Respect world matrix and reverse flag w/o normals
2022-10-21 09:16:53 +02:00
Unknown W. Brackets d23293ee72 GPU: Respect matrix and reverse flag w/o normals.
See frame dump in #14223, which requires world matrix be applied.
2022-10-20 23:15:25 -07:00
Unknown W. Brackets 6945604492 softgpu: Multiply prev normal by world matrix.
Even when it's not in the vertex data, we still must multiply by the world
matrix.  Fixes some lighting issues in Nayuta no Kiseki.
2022-10-20 23:14:54 -07:00
Unknown W. Brackets d6a59be012 softgpu: Respect negate normal flag without norm.
Per tests, Z is still negated even when using the previous normal value.
2022-10-20 23:09:48 -07:00
fp64andGitHub 2c814c568a Some more codestyle cleanup 2022-10-20 06:59:35 -04:00
fp64andGitHub 9a01db5f42 Change wrap_mode to clamp for bicubic upscaler
It was set to wrap, even though the comment claimed otherwise. Previous implementation had clamp, as do (I think) other upscaling modes (Hybrid, etc.).

Also make upscaler codestyle a little more consistent with the rest.
2022-10-20 06:53:49 -04:00
Henrik Rydgård 90d395a10d Remove "attachment" parameter from BindFramebufferAsTexture everywhere.
Not actually useful since our framebuffer objects don't support multiple
color images, and probably won't ever need to.
2022-10-20 10:15:19 +02:00
Henrik RydgårdandGitHub 8cd602a9c6 Merge pull request #16257 from unknownbrackets/error-cleanup
Kernel: Fix reported StopThread error
2022-10-19 08:06:30 +02:00
Unknown W. Brackets a42064eb48 Vulkan: Correct some enum switch warnings.
Nice to log debug annotations anyway.
2022-10-18 21:52:38 -07:00
Lubos eed75889e4 OpenXR - Ensure scene analyze is called the same way as before 2022-10-18 12:23:23 +02:00
Henrik Rydgård 269eb55c17 Build/warning fix 2022-10-18 10:48:16 +02:00
Henrik Rydgård aa51bfd1ef Use GPU "use" flags to replace IsVRBuild in the renderer. It remains elsewhere. 2022-10-17 19:57:11 +02:00
Henrik Rydgård 7c5fc3ccb5 Reorder the GPU USE flags a bit 2022-10-17 19:55:11 +02:00
Lubos 1a6180583e OpenXR - Reduce uniform calls 2022-10-17 19:00:38 +02:00
Henrik RydgårdandGitHub 123311b0c7 Merge pull request #16241 from unknownbrackets/softgpu-rect
softgpu: Correct linear interp for uneven positions
2022-10-17 09:29:31 +02:00
Henrik Rydgård 30aa07b156 Two more renames to make things read better 2022-10-17 08:47:05 +02:00
Henrik Rydgård 9b8a5d1db3 Rename GPU_SUPPORTS_ to GPU_USE_ 2022-10-17 08:47:03 +02:00
Henrik Rydgård daca0b2109 Rename gstate_c.Supports to gstate_c.Use 2022-10-17 08:46:37 +02:00
Unknown W. Brackets 162b27e136 GPU: Replace logic ops with blend for simple cases.
So that alpha/stencil are handled correctly.
2022-10-16 22:24:43 -07:00
Unknown W. Brackets 7eb7bd5141 softgpu: Correct linear interp for uneven positions.
Can't round to the pixel when calculating the S/T deltas.
This fixes issues in Wipeout (#16131) and Call of Duty bloom.
2022-10-16 18:57:55 -07:00
Unknown W. Brackets 9d6de98ed9 softgpu: Correct drawing outside TL of rectangle.
If the start coordinate was something like 51.75, we were incorrectly
drawing to 51.  This can be seen in the Metal Slug intro (#15755.)
2022-10-16 18:46:38 -07:00
Unknown W. Brackets 1931fa2f5f softgpu: Make triangle fan rect detection generic. 2022-10-16 16:01:09 -07:00
Unknown W. Brackets d33986a5ad softgpu: Cull a triangle with all negative w.
Per tests, this seems to happen but only when all points are below zero.
2022-10-15 11:49:28 -07:00
Unknown W. Brackets 4f5e821ce2 softgpu: Fix crash on screenshot w/o display. 2022-10-15 11:49:05 -07:00
Henrik Rydgård a605366254 Add ShaderId utility function to be used for some sanity checking. 2022-10-13 22:39:47 +02:00
Henrik Rydgård 4d1da5859c Add simple way to add debug annotation in the middle of the command stream. Vulkan-only. 2022-10-13 22:39:44 +02:00
Unknown W. Brackets 2f9392083a GPU: Respect stencil state in shader blend. 2022-10-11 22:26:31 -07:00
Henrik RydgårdandGitHub e0e29a1556 Merge pull request #16197 from hrydgard/more-uniform-optimization
More uniform optimization, fixes
2022-10-12 01:00:27 +02:00
Henrik Rydgård d30d8bf35c Removes the option, autodetect instead - only enable if the GPU doesn't support bitwise ops. 2022-10-11 16:09:57 +02:00
Henrik RydgårdandGitHub 901f698a10 Merge pull request #16201 from unknownbrackets/gedebugger
GE Debugger: Normalize framebuffer texture preview
2022-10-11 11:33:19 +02:00
Henrik RydgårdandGitHub 804220afb1 Merge pull request #16198 from unknownbrackets/gles-stencil
Readback stencil buffer for debugger on GLES
2022-10-11 10:55:38 +02:00
Henrik Rydgård baa9451cb7 Warning fixes 2022-10-11 09:55:53 +02:00
Unknown W. Brackets 416265431b GE Debugger: Display if tex is framebuf.
Rather than guessing based on size, let's show explicitly.
2022-10-10 22:35:42 -07:00
Unknown W. Brackets 48c39543af GE Debugger: Normalize framebuffer texture preview.
Previously, we would show the render-to-texture with its original
dimensions.  While useful, this skewed the preview coordinates and was
sometimes confusing.  Additionally, depth texturing didn't preview.

This pads and subsets the texture preview so it's the right size.
2022-10-10 21:54:24 -07:00
Unknown W. Brackets fc9f200224 GE Debugger: Centralize current fb tex fetch code. 2022-10-10 21:50:53 -07:00
Unknown W. Brackets 999055791d D3D9: Remove block transfer code overrides.
We can just use Draw now.  Keep depth, though, since it applies scale.
2022-10-10 21:48:38 -07:00
Unknown W. Brackets c89cf1cde7 D3D9: Implement CopyFramebufferToMemorySync().
This works like other backends, including D3D11.  This allows us to get
rid of the old implementation and reuse more code.
2022-10-10 21:28:14 -07:00
Unknown W. Brackets fc68cd9457 GLES: Add debug readback of stencil data.
This allows the existing gpu.buffer.renderStencil to snapshot the state.
2022-10-10 17:09:14 -07:00
Unknown W. Brackets c03d327ddd GLES: Refactor depth pipeline create.
So we can reuse for stencil as well.
2022-10-10 16:55:30 -07:00
Unknown W. Brackets 59cc7a8000 GPU: Rename stencil write pipeline. 2022-10-10 16:54:29 -07:00
Henrik Rydgård 089ac9a50e Comment about VR uniforms 2022-10-10 18:02:19 +02:00
Henrik Rydgård ee46f8992e Don't use fragmentShaderInt32Support as a replacement for checking for bitwiseOps 2022-10-10 18:02:19 +02:00
Henrik Rydgård aec22491fe Don't expand alphaColorRef to 128 bytes on backends where we don't need to. 2022-10-10 18:02:01 +02:00
Henrik RydgårdandGitHub d56bdcb81e Merge pull request #16196 from hrydgard/improved-render-stats
Improved stats in the Vulkan GPU profiler
2022-10-10 15:40:17 +02:00
Henrik Rydgård 32699da6df Vulkan (trivial): Fix numDraws stat when merging render passes. Shorten a name. 2022-10-10 10:06:30 +02:00
Unknown W. Brackets 1dc35b3ac4 GLES: Simplify, enable debug depth readback. 2022-10-10 01:04:57 -07:00
Unknown W. Brackets f8908c691b GLES: Use Draw for depth readback shader.
Was not working before, since the program was not being used by Draw2D.
2022-10-10 00:54:29 -07:00
Unknown W. Brackets 93346d6e2c GLES: Refactor depth shader download.
This makes it similar to the Draw interface.
2022-10-10 00:54:29 -07:00
Unknown W. Brackets c2da29392c GLES: Depth download cleanup. 2022-10-10 00:54:29 -07:00