Commit graph

447 commits

Author SHA1 Message Date
Unknown W. Brackets
cb3db559bd SoftGPU: Jit the linear sampling too.
For now, just reducing overhead.  Could be smarter.
2017-05-30 22:57:46 -07:00
Unknown W. Brackets
fa0ded4a76 SoftGPU: Reduce sampler id fuzz. 2017-05-30 22:57:45 -07:00
Unknown W. Brackets
c05ecfc6f1 SoftGPU: Implement separate CLUT in samplerjit. 2017-05-30 22:57:44 -07:00
Unknown W. Brackets
ffcfa0a824 SoftGPU: Specialize CLUT4 jit.
This version is a bit faster and cleaner.
2017-05-30 22:57:44 -07:00
Unknown W. Brackets
9a82ae3425 SoftGPU: Reduce overhead in sampler jit. 2017-05-30 22:57:43 -07:00
Unknown W. Brackets
2233ab073d SoftGPU: Expose jit cache for profiling. 2017-05-30 22:57:42 -07:00
Unknown W. Brackets
744736b926 SoftGPU: Jit 16 bit texel decode. 2017-05-30 22:57:42 -07:00
Unknown W. Brackets
cf32949183 SoftGPU: Jit CLUT lookup. 2017-05-30 22:57:41 -07:00
Unknown W. Brackets
a8a6b2cd8a SoftGPU: Jit swizzled texel lookup. 2017-05-30 22:57:40 -07:00
Unknown W. Brackets
c9a4679096 SoftGPU: Stop calling bufw pixels bytes.
This was never even bits, it was just 8 * pixels before.
2017-05-30 22:57:40 -07:00
Unknown W. Brackets
5491e1dbbb SoftGPU: Jit texel fetch for non-clut/non-swizzle. 2017-05-30 22:57:39 -07:00
Unknown W. Brackets
fd4c64d43d SoftGPU: Refactor out texture format logic.
This could actually be shared, nothing x86 specific...
2017-05-30 22:57:38 -07:00
Unknown W. Brackets
94920ec156 SoftGPU: Implement basic jit structure. 2017-05-30 22:57:38 -07:00
Unknown W. Brackets
1b491fe156 SoftGPU: Stub a jit for texel fetch. 2017-05-30 22:57:30 -07:00
Unknown W. Brackets
d5426e4360 SoftGPU: Move sampler code to a dedicated file. 2017-05-30 22:53:23 -07:00
Henrik Rydgård
c173da49d3 Fix a number of bugs and stuff affecting Vulkan on Mali 2017-05-30 09:36:17 +02:00
Henrik Rydgård
6bcfe539f7 Use vulkan-style clear-on-bind when switching render targets. Not optimally used yet.
Also removes a bunch of redundant render target binds.
2017-05-30 09:36:17 +02:00
Henrik Rydgård
35aefe4a2a BindBackBufferAsRenderTarget is now replaced with BindFramebufferAsRT(nullptr) 2017-05-30 09:36:17 +02:00
Unknown W. Brackets
34fe95192f GPU: Cleanup some gstate accesses. 2017-05-26 19:03:04 -07:00
Unknown W. Brackets
402eb143f7 SoftGPU: Stop calling bufw pixels bytes.
This was never even bits, it was just 8 * pixels before.
2017-05-26 19:03:03 -07:00
Unknown W. Brackets
697466ae41 SoftGPU: Support UVGen for points and lines.
Probably not used by any real games, but better to be safe in the software
renderer.
2017-05-26 19:03:02 -07:00
Unknown W. Brackets
f7a14889d3 SoftGPU: Correct mipmaps for points.
Not likely to be used, but let's make const work.
2017-05-26 18:02:55 -07:00
Henrik Rydgård
1b05a54800 Remove the Mipmap setting. One step forward for #8171 2017-05-26 10:21:20 +02:00
Henrik Rydgård
8f9e0b7fcc SoftGPU: Make sure transformunit.buf is properly aligned. Helps part of #9718 2017-05-24 10:20:10 +02:00
Unknown W. Brackets
8187927b9d SoftGPU: Use vertexjit for submitted primitives.
This uses the standard cache other rendering uses.

In Legend of Heroes 3, for example, this provides a 10% speed improvement.
2017-05-20 20:22:35 -07:00
Henrik Rydgård
ad64325876 Merge pull request #9684 from unknownbrackets/softgpu-lines
Fix lines in the software renderer
2017-05-15 08:53:46 +02:00
Unknown W. Brackets
9d64597fb3 SoftGPU: Clip lines entirely outside early.
Some were getting through, which may mean the line clipping isn't working
so well...
2017-05-14 18:28:47 -07:00
Unknown W. Brackets
672ce51a2a SoftGPU: Implement pretend antialias.
This doesn't really smooth, but at the very least faking it makes Persona
3 have less ugly lines.
2017-05-14 16:11:02 -07:00
Unknown W. Brackets
5c9d223e32 SoftGPU: Implement simple mipmapping for lines.
Mostly so the min/mag filter is correct.
2017-05-14 16:11:01 -07:00
Unknown W. Brackets
a95170d789 SoftGPU: Bias bottom right side of line drawing.
Fixes lines in Persona 2.
2017-05-14 16:11:01 -07:00
Unknown W. Brackets
a26aaec528 SoftGPU: Support flat shading for lines. 2017-05-14 16:11:00 -07:00
Unknown W. Brackets
e4f2ff1464 SoftGPU: Implement lines in transform mode. 2017-05-14 16:10:59 -07:00
Unknown W. Brackets
ad17decf5c SoftGPU: Quick hack to fix scissor w/2x2 pixels. 2017-05-14 16:02:27 -07:00
Unknown W. Brackets
8ee92048c0 SoftGPU: Avoid rcp due to precision issues.
Causes artifacts in Sword Art Online, which draws a dialog box using
stretched UVs - rcp causes the edges to sample outside the original UVs.
2017-05-14 16:02:21 -07:00
Henrik Rydgård
d13fdfbf37 Merge pull request #9683 from unknownbrackets/ge-debugger
Minor GE debugger fixes
2017-05-15 00:02:19 +02:00
Unknown W. Brackets
94c138fd83 SoftGPU: Fix texture vertex preview in debugger. 2017-05-14 14:56:23 -07:00
Unknown W. Brackets
01076dd959 SoftGPU: Don't wrap negative positions.
Haven't fully verified this, but without this, Gods Eater Burst's bloom
doesn't work, since -1,-1 maps to 1023,1023 so everything is clipped.
2017-05-13 17:28:38 -07:00
Unknown W. Brackets
b2d3058386 SoftGPU: Correct fog for rectangles.
Gods Eater Burst uses fog in its bloom, with rectangles.
2017-05-13 17:27:34 -07:00
Unknown W. Brackets
1a56466865 SoftGPU: Match GLES lighting better, use floats.
Using floats simplifies things and also makes it faster.
2017-05-13 12:54:18 -07:00
Unknown W. Brackets
86a1898732 SoftGPU: Correct rendering for pixel centers.
This should theoretically calculate everything more correctly.
2017-05-13 08:03:08 -07:00
Unknown W. Brackets
9e34601be2 SoftGPU: Correct texturing for pixel centers. 2017-05-13 07:53:39 -07:00
Unknown W. Brackets
6b0c9a5531 SoftGPU: Improve wsum recip SIMD.
A bit faster.
2017-05-13 06:56:33 -07:00
Unknown W. Brackets
7c526acc69 SoftGPU: Multiply S/T early via SIMD. 2017-05-13 06:49:27 -07:00
Unknown W. Brackets
c4d1863ded GPU: Consistently bias const mip levels.
Since SLOPE is just a more complicated CONST, we can treat them the same.
2017-05-12 20:30:47 -07:00
Unknown W. Brackets
50a775d31f SoftGPU: Calculate mip level based on float bits.
This is probably what the hardware does and much faster.
2017-05-08 20:43:02 -07:00
Unknown W. Brackets
37a4d1308f SoftGPU: Round screencoords.
It seems like this is what the PSP does, or maybe this is just correcting
for floating point error...
2017-05-08 06:50:25 -07:00
Unknown W. Brackets
92ba91366c SoftGPU: Process mipmaps in texturing. 2017-05-08 06:50:25 -07:00
Unknown W. Brackets
3944a07bf7 SoftGPU: Fix separate mipmap cluts.
These should only be used for CLUT4.
2017-05-08 06:50:24 -07:00
Unknown W. Brackets
f5dd3b9716 SoftGPU: Refactor mask calculation and use SSE.
A tiny bit faster.
2017-05-08 06:50:23 -07:00
Unknown W. Brackets
1f2c2b6d42 SoftGPU: Improve texcoord rounding.
This fixes several obvious issues in Crisis Core, but it's still wrong
when texcoords go the other direction.  Need to use the deltas.
2017-05-08 06:50:23 -07:00