Commit graph

1043 commits

Author SHA1 Message Date
Ryan Houdek
e85a3d68b0 Looks like we make use of fmod, make a GLSL function for it! 2011-12-11 07:02:13 -06:00
Pierre Bourdon
df283a56a0 More coding style fixes because I suck at sed 2011-12-11 11:14:02 +01:00
Pierre Bourdon
014c474024 8 spaces indentation -> tabs 2011-12-11 11:08:18 +01:00
Ryan Houdek
97c3c156e6 Use UBOs in every shader. I had missed a few. Only cache Uniform locations if we aren't using UBOs. 2011-12-10 15:40:10 -06:00
Ryan Houdek
c72a244809 Make sure to support everything even if GPU doesn't. 2011-12-10 14:35:37 -06:00
Ryan Houdek
5925feb6e0 yay, UBOs work 100% now. 2011-12-10 08:07:13 -06:00
Ryan Houdek
7ab38cff68 UBO works for Pixel Shaders if Binding for UBO is zero, otherwise fails. Probably why Vertex shader UBO is failing. Too tired to investigate right now. 2011-12-10 07:38:30 -06:00
Ryan Houdek
126dfa073b Firin ma lazer 2011-12-10 01:56:37 -06:00
Ryan Houdek
54a90d08ce Fix one error. 2011-12-09 21:15:15 -06:00
Ryan Houdek
e8087aa1a9 Remove bSupportsGLSLLocation since it won't work how I expect it. 2011-12-09 19:14:02 -06:00
Ryan Houdek
8e5bb59cb6 Add in UBOs, doesn't work yet. Still debugging here. 2011-12-09 17:30:05 -06:00
Ryan Houdek
9119399547 Put Vertex Uniforms in to the correct places to get ready for UBOs. 2011-12-09 16:13:04 -06:00
Ryan Houdek
c89c484dd0 Few compiler errors that got exposed once I got Dual Source Blending working. Seems it isn't working quite 100% either. Good chance I missed something anyway. 2011-12-08 05:32:17 -06:00
Ryan Houdek
0ccba2b581 Support Dual Source Blending in OGL plugin with GLSL. 2011-12-08 05:09:48 -06:00
Ryan Houdek
62b9a779c1 Playing through SSBM story made me find this. 2011-12-08 04:11:30 -06:00
Ryan Houdek
cecc3c3873 Bit of cleanup. Clean up my massive hack in the ShaderManagerFiles. Almost feature parity with Nvidia CG now I think. Just need to do Alpha test with Dual source blending now. 2011-12-08 03:20:31 -06:00
Ryan Houdek
1201988fe4 Add support for GL_ARB_shading_language_420pack so we don't have to binding sampler locations. Also add support for GL_ARB_separate_shader_objects which doesn't currently work for some reason....investigating. 2011-12-08 01:51:08 -06:00
Ryan Houdek
b01c973689 Missed one 2011-12-07 23:01:14 -06:00
Ryan Houdek
bf4ef054d3 Shader Compile fixes. Played SMS for two shines. 2011-12-07 22:47:13 -06:00
Ryan Houdek
33c24f0a15 Almost there. 2011-12-07 22:04:34 -06:00
Ryan Houdek
164b56ff73 This is the terrible bit that can't be removed until we use UBOs in the GLSL shaders. 2011-12-02 20:20:53 -06:00
Ryan Houdek
804938e9fc More stuff 2011-12-02 20:17:26 -06:00
Ryan Houdek
ae6ac5b439 moe 2011-12-02 19:04:37 -06:00
Ryan Houdek
f8eb45637f Now CG plays nice with this new stuff. 2011-12-01 00:33:12 -06:00
Ryan Houdek
b20176b74f Add in GLSL setting again.
PS and VS making. Untested and won't work for now.

Add in program shader cache files.

Readd NativeVertexFormat stuffs.

Add in PS and VS cache things.

SetShaders in places.

Fixed EFB cache index computations in OpenGL renderer.

The previous computation was very likely to go out of array bounds,
which could result in crashes on EFB access.

Also, the cache size was rounded down instead of up. This is a problem
since EFB_HEIGHT (528) is not a multiple of EFB_CACHE_RECT_SIZE (64).
2011-11-30 22:02:25 -06:00
Glenn Rice
e5d051a4e9 Update linux libav frame dump code for recent api changes. 2011-11-22 19:24:05 -06:00
Pierre Bourdon
8f31968466 Revert "Merge branch 'zcomploc-support'"
This reverts commit 9dad9ebe89, reversing
changes made to e76bc71efe.
2011-11-01 01:37:54 +01:00
crudelios
dd551814c9 Bounding Box bugfixes.
- Fixes all (I hope) BBox-related unknown pointer crashes.
- Fixes wrong BBox values with Frame Skip on (and the resulting unknown pointer crashes).
- Fixes a small oversight on the change I made to the ISO Properties dialog.

This should also be a (very very little) bit faster than the previous version.
2011-10-28 21:12:12 +01:00
crudelios
852fe9c4be Added proper Bounding Box support.
Should fix most graphical issues with Paper Mario: TTYD and Super Paper Mario. Fixes issue 360.

Since only those two games seem to require BBox support, and as per ector's suggestion, BBox is only enabled for those two games.

BBoxes and Display List Caches don't get along too well, causing Paper Mario: TTYD to hang during certain effects where BBoxes are used. For now, I disabled DList Cache for the Paper Mario games, hopefully both will be compatible in the future.
2011-10-26 01:19:10 +01:00
skidau
5d14bb5e70 Changed the save state system to load/save only after the screen has been drawn. This should help stabilise the save states. 2011-10-15 22:19:42 +11:00
Pierre Bourdon
59072adc32 Align stack variables on a 16-bytes boundary in SSSE3 functions
Fixes issue 4450. Thanks to pholklore1 for his patch.
2011-10-08 17:36:01 +02:00
Pierre Bourdon
9dad9ebe89 Merge branch 'zcomploc-support'
zcomploc is a feature of the BP which switch depth test from before the alpha
test to after the alpha test. This way, transparent fragments are written to
the depth buffer too.

The current implementation is quite hacky and does not cover all cases but is
enough to fix problems in a lot of game. A complete implementation would
require a multipass rendering method and is attempted in the
zcomploc-experimental branch.

According to testers feedback, fixes bugs in the following games:
- Baten Kaitos
- Baten Kaitos Origins
- 007: Everything or Nothing
- Ty the Tasmanian Tiger
- Tony Hawk's Pro Skater 3

And probably other games too.

Conflicts (because of new-shadercache-uids):
	Source/Core/VideoCommon/Src/PixelShaderGen.cpp
2011-10-04 07:56:13 +02:00
Pierre Bourdon
266cafb82d Add a call to VertexManager::Flush() when changing TC gen settings
In previous revisions of Dolphin, changing texture generation settings (via
GX_SetTexCoordGen for example) did not regenerate the vertex shader and flush
the vertices. Adding this flush should fix texture problems in a few game, for
example in Superman: Shadow of Apokolips:

Before: http://i.imgur.com/mHmfb.jpg
After: http://i.imgur.com/2ThES.png
2011-10-01 02:36:03 +02:00
NeoBrainX
81c614fa07 Clean up various things. 2011-09-29 23:32:39 +02:00
NeoBrainX
ddfe219293 Fixup line endings. 2011-09-29 23:32:39 +02:00
NeoBrainX
ca7e8a9e88 Fix pixel lighting. 2011-09-29 23:32:39 +02:00
NeoBrainX
f041eee23b Compile fix. 2011-09-29 23:32:38 +02:00
NeoBrainX
c710ea33f9 Merge some frame dumping code to VideoCommon, fixes a memory leak in D3D9 and OpenGL if emulation is stopped while dumping frames.
Breaks D3D11 frame dumping for some weird reason (memory corruption or whatever?).
2011-09-29 23:32:38 +02:00
NeoBrainX
bd4a5b5ef6 Implement frame dumping in D3D11.
Fixes issue 4831.
2011-09-29 23:32:38 +02:00
NeoBrainX
8c691767da Various changes which improve FreeBSD support.
Patches by martymac, all credits go to him ;)
2011-09-29 23:32:38 +02:00
NeoBrainX
5d075ce507 - D3D9: pass the correct API type to ValidatePixelShaderIDs
- don't load shader cache from disk in d3d9/11 if shader debugging is enabled (we won't have any info about the source shader code otherwise, etc)
- dump shader source codes on safe UIDs mismatch

Thanks to LordMark and [SS] for reporting those to me ;)
2011-09-10 03:10:28 +02:00
NeoBrainX
a021dd7b79 Small fix to the previous commit. 2011-09-09 21:45:11 +02:00
NeoBrainX
5c14a24ce1 Make shader ID validation optional by adding a gfx setting called "EnableShaderDebugging".
Setting this to True will enable additional checks if the shader cache misses any relevant register changes.
2011-09-09 21:34:46 +02:00
NeoBrainX
b28348066e Improve the shader UID debugging stuff and merge it to VideoCommon, effectively enabling it in D3D9 and D3D11 as well. 2011-09-09 00:32:04 +02:00
NeoBrainX
349a3ae91d Merge remote-tracking branch 'remotes/origin/master' into new-shadercache-uids 2011-09-08 02:14:18 +02:00
NeoBrainX
6c7bda6851 Various fixes and cleanups. 2011-09-08 02:09:44 +02:00
NeoBrainX
98b62d8362 Track alpha blending paramaters in the pixel shader UID. 2011-09-07 21:15:14 +02:00
NeoBrainX
3939f9595a Add runtime checks to make sure we aren't overoptimizing the pixel shader cache. 2011-09-07 21:15:09 +02:00
NeoBrainX
4702de591e Added safe pixel shader UIDs for debugging purposes. 2011-09-07 21:10:06 +02:00
NeoBrainX
231c13d6ce Added safe vertex shader UIDs for debugging purposes. 2011-09-07 21:03:10 +02:00