Commit graph

1902 commits

Author SHA1 Message Date
Subv
c42b8cbdd0 Shaders: Implemented a stack for the SSY/SYNC instructions.
The SSY instruction pushes an address into the stack, and the SYNC instruction pops it. The current stack depth is 20, we should figure out if this is enough or not.
2018-08-18 10:48:12 -05:00
Subv
a175f7ba29 Shaders: Corrected the 'abs' and 'neg' bit usage in the float arithmetic instructions.
We should definitely audit our shader generator for more errors like this.
2018-08-18 10:22:42 -05:00
David Marcec
ab3b9d7aa5 Added predcondition GreaterThanWithNan 2018-08-18 17:49:59 +10:00
bunnei
80714d89d6 Merge pull request #1096 from bunnei/supported-blits
gl_rasterizer_cache: Remove asserts for supported blits.
2018-08-17 22:41:53 -04:00
bunnei
9705148ea2 gl_rasterizer_cache: Remove asserts for supported blits. 2018-08-17 00:10:08 -04:00
bunnei
aeea1e9108 renderer_opengl: Treat OpenGL errors as critical. 2018-08-17 00:09:27 -04:00
bunnei
5912824519 Merge pull request #1019 from Subv/vertex_divisor
Rasterizer: Manually implemented instanced rendering.
2018-08-17 00:07:06 -04:00
bunnei
9b74ac4e98 gl_rasterizer_cache: Treat Depth formats differently from DepthStencil. 2018-08-15 21:24:04 -04:00
Subv
64cb9fc8b0 Shader/Conversion: Implemented the negate bit in F2F and I2I instructions. 2018-08-15 09:27:43 -05:00
Subv
237848d417 Shader/I2F: Implemented the negate I2F_C instruction variant. 2018-08-15 09:25:02 -05:00
Subv
61be8e0be3 Shader/F2I: Implemented the negate bit in the I2F instruction 2018-08-15 09:18:55 -05:00
Subv
cb60077c0c Shader/F2I: Implemented the F2I_C instruction variant. 2018-08-15 09:16:35 -05:00
Subv
e0c412ae9b Shader/F2I: Implemented the negate bit in the F2I instruction. 2018-08-15 09:15:55 -05:00
bunnei
a617634394 Merge pull request #1077 from bunnei/rgba16u
gl_rasterizer_cache: Add RGBA16U to PixelFormatFromTextureFormat.
2018-08-15 09:25:15 -04:00
bunnei
5135d2a415 gl_rasterizer_cache: Cleanup some PixelFormat names and logging. 2018-08-14 23:31:45 -04:00
Subv
1162a49920 Rasterizer: Implemented instanced rendering.
We keep track of the current instance and update an uniform in the shaders to let them know which instance they are.

Instanced vertex arrays are not yet implemented.
2018-08-14 22:25:07 -05:00
bunnei
359480e0dc gl_rasterizer_cache: Add RGBA16U to PixelFormatFromTextureFormat.
- Used by Breath of the Wild.
2018-08-14 23:18:34 -04:00
bunnei
e8fe32f9d5 Merge pull request #1069 from bunnei/vtx-sz
maxwell_to_gl: Properly handle UnsignedInt/SignedInt sizes.
2018-08-14 23:14:44 -04:00
bunnei
b5c3d5e9f2 Merge pull request #1070 from bunnei/cbuf-sz
gl_rasterizer: Fix upload size for constant buffers.
2018-08-14 23:14:24 -04:00
bunnei
64aa1ad9cd Merge pull request #1071 from bunnei/fix-ldc
gl_shader_decompiler: Several fixes for indirect constant buffer loads.
2018-08-14 23:14:09 -04:00
bunnei
d36398658b Merge pull request #1068 from bunnei/g8r8s
gl_rasterizer_cache: Implement G8R8S format.
2018-08-14 23:13:43 -04:00
greggameplayer
e4e15aa6c5 Implement Z16_UNORM in PixelFormatFromTextureFormat function
Require by Zelda Breath Of The Wild
2018-08-15 04:14:15 +02:00
bunnei
8b86f91e1a gl_shader_decompiler: Several fixes for indirect constant buffer loads. 2018-08-14 20:47:50 -04:00
bunnei
e6b29a30db gl_rasterizer: Fix upload size for constant buffers. 2018-08-14 20:44:19 -04:00
bunnei
debc3f9176 maxwell_to_gl: Properly handle UnsignedInt/SignedInt sizes. 2018-08-14 20:43:02 -04:00
bunnei
f5ec085815 gl_rasterizer_cache: Implement G8R8S format.
- Used by Super Mario Odyssey.
2018-08-14 20:41:49 -04:00
bunnei
4931d9c7d1 Merge pull request #1058 from greggameplayer/BC7U_Fix
Fix BC7U
2018-08-14 08:03:07 -04:00
greggameplayer
dd3e4a2b75 Fix BC7U 2018-08-14 02:36:00 +02:00
bunnei
9b9cf62587 renderer_opengl: Implement RenderTargetFormat::RGBA16_UNORM.
- Used by Breath of the Wild.
2018-08-13 18:20:07 -04:00
bunnei
3cdfb2d11f Merge pull request #1052 from ogniK5377/xeno
Implement RG32UI and R32UI
2018-08-13 12:31:39 -04:00
David Marcec
5c1a4ab132 Implement RG32UI and R32UI
Needed for xenoblade
2018-08-13 22:55:16 +10:00
bunnei
71faea40a6 maxwell_to_gl: Implement VertexAttribute::Size::Size_8.
- Used by Breath of the Wild.
2018-08-13 01:34:21 -04:00
bunnei
1d2fdc5a0d renderer_opengl: Implement RenderTargetFormat::RGBA16_UINT.
- Used by Breath of the Wild.
2018-08-13 00:06:22 -04:00
bunnei
f9c5041caa Merge pull request #1045 from bunnei/rg8-unorm
renderer_opengl: Implement RenderTargetFormat::RG8_UNORM.
2018-08-13 00:05:25 -04:00
bunnei
dcd05b3e87 maxwell_to_gl: Implement PrimitiveTopology::LineStrip.
- Used by Breath of the Wild.
2018-08-12 23:09:32 -04:00
bunnei
ad6b0268eb renderer_opengl: Implement RenderTargetFormat::RG8_UNORM.
- Used by Breath of the Wild.
2018-08-12 23:08:50 -04:00
bunnei
03ac254de6 gl_shader_decompiler: Implement XMAD instruction. 2018-08-12 18:30:24 -04:00
Markus Wick
d6703d607b gl_rasterizer: Use a shared helper to upload from CPU memory. 2018-08-12 16:10:26 +02:00
Markus Wick
2d2027cd52 gl_state: Don't track constant buffer mappings. 2018-08-12 16:10:26 +02:00
Markus Wick
a59891f497 gl_rasterizer: Use the stream buffer for constant buffers. 2018-08-12 16:10:26 +02:00
Markus Wick
b4f88b06b5 gl_rasterizer: Use the streaming buffer itself for the constant buffer.
Don't emut copies, especially not for data, which is used once. They just end in a huge GPU overhead.
2018-08-12 15:48:59 +02:00
Markus Wick
ca4e2c22d4 gl_rasterizer: Use a helper for aligning the buffer. 2018-08-12 15:47:35 +02:00
Markus Wick
73b40c2bd4 Update the stream_buffer helper from Citra.
Please see https://github.com/citra-emu/citra/pull/3666 for more details.
2018-08-12 15:47:35 +02:00
bunnei
7f1a8483e9 gl_shader_decompiler: Fix SetOutputAttributeToRegister empty check. 2018-08-12 02:22:42 -04:00
bunnei
7031b3b762 gl_shader_decompiler: Fix GLSL compiler error with KIL instruction. 2018-08-12 00:06:48 -04:00
bunnei
db6b59b1a6 Merge pull request #1020 from lioncash/namespace
core: Namespace EmuWindow
2018-08-11 22:40:08 -04:00
bunnei
947d80c8ce Merge pull request #1021 from lioncash/warn
gl_rasterizer: Silence implicit truncation warning in SetupShaders()
2018-08-11 22:39:46 -04:00
bunnei
f807476d29 Merge pull request #1024 from Subv/blend_gl
GPU/Maxwell3D: Implemented an alternative set of blend factors.
2018-08-11 22:39:02 -04:00
bunnei
7478448af7 Merge pull request #1023 from Subv/invalid_attribs
RasterizerGL: Ignore invalid/unset vertex attributes.
2018-08-11 22:18:40 -04:00
Subv
45ee826309 GPU/Maxwell3D: Implemented an alternative set of blend factors.
These are used by nouveau and some games like SMO.
2018-08-11 20:57:16 -05:00