Henrik Rydgård
f56ef63ef5
Remove redundant function
2023-05-23 16:50:25 +02:00
Henrik Rydgård
d51d1413a3
DrawEngineCommon: Rename decoded to decoded_
2023-05-23 16:46:43 +02:00
Henrik Rydgård
d7ea2ebf8a
GL: Add tags to push buffers for debug purposes. Double the default vertex buffer size.
2023-05-23 15:53:41 +02:00
Henrik Rydgård
a4baed4c0c
Minor GLPushBuffer cleanup (now same API as the VK one)
2023-05-23 08:41:09 +02:00
Henrik Rydgård
b27c427547
We always bind and draw together, so let's combine them to one command.
2023-05-10 10:56:25 +02:00
Henrik Rydgård
8f2069ef71
GLQueueRunner: Combine BindVertexBuffer with BindIndexBuffer
2023-05-10 09:23:10 +02:00
Henrik Rydgård
c80671d9ea
Debug-assert that there's a renderpass in Flush instead of asserting, and skip if not.
...
buildfix
2023-05-03 23:49:38 +02:00
Henrik Rydgård
7c420381d5
OpenGL: Some paranoia checks around failed shader generation
2023-05-01 12:11:34 +02:00
Henrik Rydgård
d4249c1d73
OpenGL: Add an assert to catch a class of crash bugs early. Also assorted paranoia.
2023-05-01 11:56:26 +02:00
Henrik Rydgård
16b243b007
Centralize allocation of vertex decode buffers
2023-04-24 12:11:58 +02:00
Unknown W. Brackets
1f91993e7d
GLES: Apply vertex limit only to GLES2.
2023-01-08 11:06:35 -08:00
Henrik Rydgård
85e6b4e592
Increment numFlushes near the other stat increments
...
Might be better for the cache, heh.
2023-01-04 17:10:56 +01:00
Henrik Rydgård
f069de2dd2
Pass the vertex decoder into the vertex shader IDs generator
...
Instead of just the vertex type.
This will allow things like the vertex decoder supplying defaults, in
order to reduce the number of unique vertex shaders at the cost of
slightly larger vertex data.
This doesn't actually do that yet though, it's just a refactor that can
be done separately.
Part of #16567
2022-12-30 22:57:05 +01:00
Unknown W. Brackets
49f6c461ad
Reporting: Fix some header includes.
...
Particularly in Common, avoid including Core/Reporting.h.
2022-12-27 14:58:20 -08:00
Unknown W. Brackets
e5dbdba638
GPU: Keep prevPrim_ set on flush.
...
For continuing previous verts, see #16612 . We still don't handle these
quite accurately (outside software rendering), but this should be better.
2022-12-18 07:14:19 -08:00
Unknown W. Brackets
f44852bb18
Global: Cleanup virtual/override specifiers.
...
Also missing virtual destructors, hidden non-overrides, etc.
2022-12-10 21:13:36 -08:00
Henrik Rydgård
331d024a8c
Add a flags parameter to InvalidateCachedState and rename it Invalidate.
...
Also rename the old InvalidationFlags enum to InvalidateCallbackFlags.
2022-12-01 19:15:38 +01:00
Henrik Rydgård
bdfde4cbac
Implement the new screen sizing parameters
2022-11-27 16:16:04 +01:00
Henrik Rydgård
3dd45c6561
Can't forget the texture in the callback, breaks texture-from-framebuffer-copy.
...
Was probably redundant anyway.
2022-11-24 11:02:21 +01:00
Henrik Rydgård
70d1d8fa07
Replace the "GetCurrentStepId"-based state invalidation with callbacks
2022-11-24 10:52:42 +01:00
Unknown W. Brackets
70c3205564
GPU: Correct equal depth checks.
2022-11-09 20:34:29 -08:00
Unknown W. Brackets
1c0a37f252
GPU: Correct vertex decoder in software transform.
...
It was meant to flip to skin in decode.
2022-11-09 07:07:39 -08:00
Unknown W. Brackets
3333f2a5aa
GPU: Avoid clears for non-simple depth values.
...
Some drivers don't round depth the same way for a clear vs for drawing,
which can cause mismatches. We only do this if we see equals-style depth
comparison funcs used in drawing.
2022-11-08 20:06:08 -08:00
Unknown W. Brackets
3de2557ecb
GPU: Always skin in decode for software transform.
2022-11-06 08:55:07 -08:00
Unknown W. Brackets
6c36f03a0d
GPU: Purify vertTypeIsSkinningEnabled().
2022-11-06 08:40:54 -08:00
Henrik Rydgård
7c5fc3ccb5
Reorder the GPU USE flags a bit
2022-10-17 19:55:11 +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
b9b59f7806
GPU: Mask away unused bits in framebuf/zbuf ptr.
...
Lower 4 bits are ignored during rendering, and mirrors (even even the 8
bit at the top) are ignored.
2022-10-02 20:44:35 -07:00
Unknown W. Brackets
a8eced4773
GLES: Avoid resizing tessellation data textures.
...
Just recreate when it needs to be larger. Fixes Test Drive Unlimited
issues noted in #16069 .
2022-09-21 23:30:00 -07:00
Henrik Rydgård
b84cda2876
Plumb the computed pipeline state into ComputeFragmentShaderID.
2022-09-02 22:16:57 +02:00
Henrik Rydgård
586da08820
Merge pull request #15895 from unknownbrackets/gpu-minor
...
GPU: Correct Draw2D::DeviceRestore()
2022-08-24 11:50:42 +02:00
Henrik Rydgård
eb2f12e64a
Drive-by texture slot management cleanup
2022-08-24 10:22:58 +02:00
Unknown W. Brackets
7ec62a32b4
GPU: More consistently clear ptrs on DeviceLost().
...
Rather get a null pointer crash than confusing buggy use-after-free
excitement.
2022-08-23 20:15:30 -07:00
Unknown W. Brackets
b5a4843c1f
GPU: Purify ConvertViewportAndScissor().
...
This makes it harder to misuse. See #15856 .
2022-08-20 14:21:11 -07:00
Unknown W. Brackets
d61619db47
GPU: Dirty params when converting viewport state.
...
This flag will be false when we convert next time, so parameters won't get
updated as expected.
2022-08-20 14:03:24 -07:00
Henrik Rydgård
12db0e52d4
Fix deferred-depth for bezier/spline. Move updating of last_frame_depth_render to GPUCommon.
2022-08-20 08:29:33 +02:00
Henrik Rydgård
08e2d951b4
State handling reordering in D3D11 and D3D9 backends.
2022-08-05 23:07:01 +02:00
Henrik Rydgård
fecf9127a0
Implement 3D texturing in the OpenGL backend too. Assorted fixes.
2022-07-31 10:43:48 +02:00
Henrik Rydgård
9ffb248e59
Merge pull request #15646 from unknownbrackets/report-vertex
...
Reporting: Log when vertex count truncated
2022-07-04 23:23:36 +02:00
Unknown W. Brackets
efacbddaef
Reporting: Log when vertex count truncated.
2022-07-04 13:22:17 -07:00
Unknown W. Brackets
feddff8299
GLES: Fix sw transform flip in skip buffer mode.
...
Was causing some things to be drawn in the wrong places and upside down.
2022-06-05 11:31:07 -07:00
Henrik Rydgård
7be86264d0
Move framebufFormat to gstate_c, so we can override it
2022-04-30 18:16:09 +02:00
Henrik Rydgård
b88d676f78
Remove the vertex cache from the OpenGL backend.
...
It was disabled for a very long time, and now that we've re-enabled it, it
mostly causes problems.
Not feeling like debugging it on weird hardware, I think it's better
to focus energy on other optimizations.
2021-11-06 00:45:43 +01:00
Unknown W. Brackets
2718e81c0e
GPU: Expand lines to triangles.
2021-10-31 14:46:46 -07:00
Unknown W. Brackets
b3a8e013f6
GPU: Expand points into triangles for higher res.
2021-10-31 13:06:06 -07:00
Unknown W. Brackets
5128480d74
GPU: Implement cull behavior in sw transform.
2021-10-30 21:04:16 -07:00
Unknown W. Brackets
4ec75de0e7
GPU: Add fog separately for swtransform verts.
...
At this point, still being processed wrong, this just changes the
attribute structure.
2021-10-30 18:22:54 -07:00
Unknown W. Brackets
159eab5141
GPU: Set projection matrix per backend.
...
There's a bit of variance, so this keeps the central code clean.
2021-10-30 18:20:36 -07:00
Unknown W. Brackets
f35c7d04bd
GPU: Update viewport params before sw transform.
2021-10-30 18:19:16 -07:00