Commit Graph
40 Commits
Author SHA1 Message Date
Henrik Rydgård 795ddf16e5 Mipmaps: Use a uniform to specify the texture lod in SLOPE and CONST modes. Fixes the mipmap test for D3D11, Vulkan and modern GL properly, while keeping Tony Hawk games working.
Also implements increasing the lod level with the render resolution
properly.
2017-12-08 15:53:49 +01:00
Unknown W. Brackets 9f000ddf35 GLES: Avoid hanging while precompiling shaders.
We want to continue updating the screen so it doesn't seem frozen.
2017-12-03 11:30:00 -08:00
Unknown W. Brackets 681ce953ec GLES: Log shader cache filesize error better. 2017-12-02 10:20:44 -08:00
Unknown W. Brackets e50ec2c350 GLES: Validate shader cache filesize on preload. 2017-12-02 09:14:19 -08:00
Unknown W. Brackets 4731a2918c GPU: Use more typesafe shader IDs.
Since they really are fairly distinct, let's make sure we can't mix them
accidentally.
2017-12-02 09:07:27 -08:00
Henrik RydgårdandGitHub a67357db05 Merge pull request #10223 from unknownbrackets/minor
Reporting: Use a different link message on preload
2017-12-01 20:28:37 +01:00
Unknown W. Brackets 2a540de329 Reporting: Use a different link message on preload.
May help us determine if this only happens from a corrupt cache.
2017-12-01 11:17:51 -08:00
Henrik Rydgård 8a58b768f1 Check for HW-transform and through when loading GL shader cache. 2017-12-01 11:32:16 +01:00
Henrik RydgårdandGitHub 24e5fbc115 Merge pull request #10215 from unknownbrackets/minor
Improvements for things found in reporting
2017-12-01 00:54:39 +01:00
Unknown W. Brackets e0ccbd31b6 GLES: Report shader errors with shader desc. 2017-11-30 15:34:29 -08:00
Henrik Rydgård 7b2ad5fe72 Add some debug asserts, useful for debugging shader mismatches locally (though haven't found any..) 2017-12-01 00:28:07 +01:00
Henrik Rydgård 3e011238c5 Fix minor discrepancy in shader ID calculation, I don't think this will fix anything though. Bumping shader cache version and doing minor cleanup too. 2017-11-30 22:44:39 +01:00
Henrik Rydgård 2c86217552 Cleanup GPU vendor detection a bit, use it to avoid the issue mentioned in #9545 2017-11-21 16:19:28 +01:00
Henrik Rydgård 33d3d2f178 GL: Compute "availableUniform" when generating shaders instead of by querying. 2017-11-19 11:25:31 +01:00
Henrik Rydgård 32df9e25da GL: Compute the attrMask while generating the vshader instead of querying.
This will help in the future when we defer GL rendering like we did Vulkan - we will be able to use uniforms, but we won't be able to react to the result of these queries immediately.

Also slightly faster though noone will notice.
2017-11-19 11:24:32 +01:00
Unknown W. Brackets 72e0a24724 GPU: Reset shader state on shader reset.
Was ending up with lastFSID being -1, but being used.

Seen in gpu/commands/blend test.
2017-09-20 08:37:54 -07:00
Henrik Rydgård 871fa713ed Fix bug in vulkan init. Add some sanity checks to GL shader cache loading. 2017-08-28 15:22:18 +02:00
Henrik Rydgård 4938ab786e Fix possible crash when loading GL shader caches. Should help #9930. 2017-08-25 22:49:51 +02:00
Henrik Rydgård 91a0331f99 Bump the GL shader cache version 2017-08-24 14:58:13 +02:00
Henrik Rydgård b21ed852ce Switch over the GL shader manager to the new hashmaps. 2017-08-20 19:29:43 +02:00
Henrik Rydgård c2bd739b49 Optimize uniform uploads for D3D9 and GL as well. 2017-08-20 13:53:39 +02:00
Henrik Rydgard 078e1151f9 Dirty-flag the fragment shader ID. 2017-08-14 11:36:07 +02:00
Henrik Rydgard 56cd991833 All: Only recompute the vertex shader ID when dirty 2017-08-14 11:36:06 +02:00
Unknown W. Brackets d4ff7cc928 Spline: Simplify uniforms/dirty to one check.
This makes backends more consistent in which values they use, and reduces
the (relatively uncommon compared to other drawcalls) dirty checks for
splines.
2017-03-19 20:05:56 -07:00
Unknown W. Brackets ad8a0e6cc0 Add an ini setting to hide performance warnings. 2017-03-11 19:31:00 -08:00
Henrik Rydgard 5d4700ae7e Sprinkle calls to CHECK_GL_ERROR_IF_DEBUG all over the place, disabled by default. 2017-03-03 14:18:40 +01:00
xebra 0172bbe8aa [spline/bezier]Minor fixes for HW tess GLES. 2017-02-25 18:40:20 +09:00
Henrik Rydgard ba95e0f4d9 Initial stab at porting the DX9 backend to D3D11. Not working yet. 2017-02-09 13:28:40 +01:00
Henrik Rydgard f1c96c056d Move all the GL/D3D9 FBO code into thin3d. 2017-02-06 11:40:16 +01:00
Henrik Rydgard 2a231b397b Unbreak environment mapping 2017-01-30 16:13:47 +01:00
Henrik Rydgard 0e4fb11a2d If we can predict that the texcoord.z will always be 1.0 after the matrix, skip texture projection. Should help #9189 2017-01-30 16:03:57 +01:00
Henrik Rydgard 24cc3dbc70 Always pass vec3 texcoord between vertex and fragment shader, to allow for some simplification. 2017-01-30 16:03:57 +01:00
Henrik Rydgard e59cafe177 Don't rely on gstate_c.spline or bezier during shader compile, as that doesn't work with the cache. Should fix #9249 2017-01-28 22:34:10 +01:00
Henrik Rydgård d5d9d87dc6 Update the shader cache version to avoid obsolete shaders sticking around. Should fix #9249. 2017-01-28 22:11:48 +01:00
Henrik Rydgard e4cb44c243 Merge the texture flags into the dirty flags 2017-01-24 18:12:20 +01:00
Henrik Rydgard b423998c36 Move uniform dirty-flag to gstate_c, opening up for other uses. 2017-01-24 18:12:20 +01:00
Henrik Rydgard 3c221a7ebd Extract the dirty flag from the shader managers so code that dirties uniform flags can be shared. 2017-01-23 21:11:39 +01:00
Henrik Rydgard 63c00ec528 Don't need to take vertex format into account when applying UV scale for spline/bezier 2017-01-23 17:44:13 +01:00
Henrik Rydgard bd4436c6eb Centralize EstimatePerVertexCost and Execute_BlockTransferStart 2017-01-23 17:22:17 +01:00
Henrik Rydgard d9acd27126 Rename GLES files to match the convention the other backends use. 2017-01-23 17:08:58 +01:00