Commit Graph
75 Commits
Author SHA1 Message Date
Henrik Rydgård 642f2004d3 Start working on getting tess to match 2020-11-01 19:58:53 +01:00
Henrik Rydgård ba7c2e856b Fix through mode differences 2020-11-01 19:58:50 +01:00
Henrik Rydgård 9b3662460c Make the lighting code match 2020-11-01 19:58:50 +01:00
Henrik Rydgård 8efb40180e Make the hardware skinning code match 2020-11-01 19:58:50 +01:00
Henrik Rydgård b6992e428b More HLSL work. Some vertex shaders are starting to pass. 2020-11-01 19:58:50 +01:00
Henrik Rydgård fbb7f72eec Vertex shader merge work 2020-11-01 19:58:45 +01:00
Henrik Rydgård 105a6ce920 Oops, seems I screwed those #version statements up worse. 2020-11-01 19:53:08 +01:00
Henrik Rydgård 4053c3d1ec Fix #version statement for GLES 2.0 vertex shaders 2020-11-01 19:42:33 +01:00
Henrik Rydgård 0938d495d9 Remove a redundant bit from vertex shader IDs.
(complicates automated testing of shader generation)

Should have no noticeable effects.
2020-11-01 11:48:55 +01:00
Henrik Rydgård 042f799573 Fix silly issue in vertex shader gen 2020-10-31 22:59:38 +01:00
Henrik Rydgård 0b1b36921e Move the now-renamed fragment shader generator to GPU/Common. 2020-10-31 19:03:14 +01:00
Henrik Rydgård b7d674411e Test parsing of generated OpenGL shaders too (by using glslang). 2020-10-31 18:32:43 +01:00
Henrik Rydgård c2a6090c3f More D3D9 fixes. 2020-10-31 18:32:43 +01:00
Henrik Rydgård af4d6e7642 Set up the test for D3D9, start fixing stuff. 2020-10-31 18:32:43 +01:00
Henrik Rydgård fb2ac3a67e Additional fixes 2020-10-25 08:34:35 +01:00
Henrik Rydgård 69c8912b93 More tess fixes 2020-10-25 08:34:35 +01:00
Henrik Rydgård 6055350a2c Initial work on fixing tess 2020-10-25 08:34:35 +01:00
Henrik Rydgård 7532116b69 Fix additional minor differences 2020-10-25 08:34:35 +01:00
Henrik Rydgård a8f4a4d749 Fix more vertex shader differences 2020-10-25 08:34:35 +01:00
Henrik Rydgård 057fd9f8a3 Bridge more vertex shader differences 2020-10-25 08:34:35 +01:00
Henrik Rydgård 22b26ffc09 Time for the vertex shaders. Set up a test, start eliminating differences. 2020-10-25 08:34:35 +01:00
Henrik Rydgård 9e245d6835 OpenGL: Share the shader version detection.
Use a version integer instead of a string
2020-10-23 10:03:44 +02:00
Henrik Rydgård c45515866b Cleanup
Clean up GLSL language setup further
2020-10-23 10:03:44 +02:00
Henrik Rydgård 2917b0e9e6 GLES: Read compat params first, emit code later. 2020-10-23 10:03:44 +02:00
Henrik Rydgård 2c0a3c2e23 Prepare for more GLSL testing 2020-10-21 23:39:34 +02:00
Henrik Rydgård 3d36049b65 Rename shader generator functions, a bit of moving around and adding an errorString param. 2020-10-21 23:20:25 +02:00
Henrik Rydgård 391d2ea73d Rename vk uniforms to match the other backends 2020-10-21 21:13:08 +02:00
Henrik Rydgård 0e3a84b4a8 Move most GPU things to Common.
It works after the move, on Windows and Android at least.

Deletes the D3DX9 shader compiler loader, which was not used.
2020-10-04 23:39:02 +02:00
Henrik Rydgård ed88761ecc Merge ext/native/stringutil.cpp/h into Common/StringUtils.cpp/h. 2020-09-29 15:51:51 +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
Henrik Rydgård 09b5546828 Apply the same Mali range culling "fix" in OpenGL. 2019-08-09 00:09:06 +02:00
Unknown W. Brackets 1c19bce514 GPU: Correct specular exponent zero. 2018-11-22 08:53:25 -08:00
Unknown W. Brackets 4816bfc1a6 GPU: Skip specular on negative diffuse factor.
This is correct per hardware tests, see #8403.  Note that the PS3 emulator
running PSP HD remasters does not correctly handle this, and applies
specular for negative diffuse factor.
2018-11-22 08:53:25 -08:00
Unknown W. Brackets 6e46d6c0f9 GPU: Correct powered diffuse with exp=0.
Just to ensure negative factors are handled too, as they are on hardware.
2018-11-22 08:53:25 -08:00
Unknown W. Brackets 1cec9f5ea1 GPU: Handle spot light with 0 exp or length. 2018-11-22 08:53:25 -08:00
Unknown W. Brackets 9a4cd5bd9d GPU: Skip specular on powered diffuse.
Matches hardware tests and improves lighting for Virtua Tennis, see #4140.
2018-11-22 07:59:56 -08:00
Unknown W. Brackets 0c5c776bb9 GPU: Correct shade mapping with 0,0,0 light pos.
May need to audit more normalize() usage, if it's consistent in other
places.
2018-11-17 18:33:07 -08:00
Henrik RydgårdandGitHub 22c066515e Merge pull request #11425 from xebra/refactor_spline_bezier
[Refactoring] Improve spline/bezier.
2018-11-04 17:04:29 +01:00
Henrik Rydgård fa40bcff8d Disable triangle range culling on D3D9 on Intel. Should fix #11477 2018-10-21 09:36:15 +02:00
xebra 41823f8780 [spline/bezier]Fix GLES texture resolution of HW tess to real 2D to avoid huge width in FF4CC mist dragon morphing. 2018-10-07 23:54:23 +09:00
xebra 89786b943d [spline/bezier]Instanced rendering for B-Spline is very slow when using weak GPU, so disabled it and simplify the shaders.
Add changing the quality of HW tessellation.
2018-10-07 23:54:22 +09:00
xebra 3216a83a92 [spline/bezier]Expand loops in the shaders. 2018-10-07 23:54:14 +09:00
xebra 8c279c0e25 [spline/bezier]Precalculate weights in the shaders using the outer product. 2018-10-07 23:54:13 +09:00
xebra 453e274fbe [spline/bezier]Fix around vertex type flags. 2018-10-07 23:54:11 +09:00
xebra d4a667397c [spline/bezier]Improve shader uniforms a bit. 2018-10-07 23:54:10 +09:00
xebra de5975f13e [spline/bezier]Reduce multiplications in the shaders from 16 to 4. 2018-10-07 23:54:09 +09:00
xebra 103d180ae7 [spline/bezier]Get rid of wasted if-checks at Graphics Processors. 2018-10-07 23:54:08 +09:00
xebra 41d6c3cf3a [spline/bezier]Move whole tessellation logic in the shaders into a subroutine. 2018-10-07 23:54:08 +09:00
xebra 3d07bca010 [spline/bezier]Fix spline weights calculation and get rid of using next patch position in hwtess.
# Conflicts:
#	GPU/Directx9/VertexShaderGeneratorDX9.cpp
#	GPU/GLES/VertexShaderGeneratorGLES.cpp
#	GPU/Vulkan/VertexShaderGeneratorVulkan.cpp
2018-10-07 23:54:07 +09:00
xebra 3c0fb44f2e [spline/bezier]Improve hwtess to use cached weights. 2018-10-07 23:54:05 +09:00