Commit graph

8329 commits

Author SHA1 Message Date
Ryan Houdek
a809feae1a Disable UBO buffer generation if hardware doesn't support it. 2012-10-09 23:41:48 -05:00
Pierre Bourdon
3bcec51334 More coding style fixes because I suck at sed 2012-10-09 23:41:48 -05:00
Pierre Bourdon
3c6d0fc710 8 spaces indentation -> tabs 2012-10-09 23:41:48 -05:00
Ryan Houdek
a5257c1a0a Actually have Dual Source blending work for people. Forgot about this change. 2012-10-09 23:41:06 -05:00
Ryan Houdek
a304af75fd Make this pretty 2012-10-09 23:41:06 -05:00
Ryan Houdek
67687a7b6d Make sure our UBO buffers are always aligned correctly. 2012-10-09 23:41:06 -05:00
Ryan Houdek
5b06bbf87d Use UBOs in every shader. I had missed a few. Only cache Uniform locations if we aren't using UBOs. 2012-10-09 23:41:06 -05:00
Ryan Houdek
5bcbf92f43 Make sure to support everything even if GPU doesn't. 2012-10-09 23:41:06 -05:00
Ryan Houdek
d4a80ca3ec yay, UBOs work 100% now. 2012-10-09 23:41:05 -05:00
Ryan Houdek
1f75ee49bf 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. 2012-10-09 23:41:05 -05:00
Ryan Houdek
904adb9e3d More for Billiard <3 2012-10-09 23:41:05 -05:00
Ryan Houdek
ce7a54f32a Firin ma lazer 2012-10-09 23:41:05 -05:00
Ryan Houdek
b105d70339 Firin ma lazer 2012-10-09 23:41:05 -05:00
Ryan Houdek
c82b92bfc2 Fix one error. 2012-10-09 23:41:05 -05:00
Ryan Houdek
2fbca145cb Remove bSupportsGLSLLocation since it won't work how I expect it. 2012-10-09 23:41:05 -05:00
Ryan Houdek
4a84c6f742 Add in UBOs, doesn't work yet. Still debugging here. 2012-10-09 23:41:05 -05:00
LPFaint99
5f0f26ef35 add ProgramShaderCache.* to visual studio project files 2012-10-09 23:41:05 -05:00
Ryan Houdek
76e5766a1b Put Vertex Uniforms in to the correct places to get ready for UBOs. 2012-10-09 23:41:04 -05:00
Ryan Houdek
d897491f94 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. 2012-10-09 23:41:04 -05:00
Ryan Houdek
d83ead5914 Support Dual Source Blending in OGL plugin with GLSL. 2012-10-09 23:39:16 -05:00
Ryan Houdek
eff019442f Playing through SSBM story made me find this. 2012-10-09 23:37:52 -05:00
Ryan Houdek
b24990ca28 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. 2012-10-09 23:37:52 -05:00
Ryan Houdek
cf68cc0c61 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. 2012-10-09 23:37:52 -05:00
Ryan Houdek
081ad949ce Welp, just fixed that problem. 2012-10-09 23:35:45 -05:00
Ryan Houdek
3c9c5de722 Missed a spot. Most games work now, Still have a problem with viewtiful joe. Destination Alpha pass doesn't work yet, going to use Dual source blending on that. 2012-10-09 23:35:45 -05:00
Ryan Houdek
8058f2f32f Missed one 2012-10-09 23:33:02 -05:00
Ryan Houdek
9064b76deb Shader Compile fixes. Played SMS for two shines. 2012-10-09 23:33:02 -05:00
Ryan Houdek
3160da1289 This lets us see stuff with GLSL shaders. Just need to take care of some compile errors now. 2012-10-09 23:33:02 -05:00
Ryan Houdek
7cec31dbf3 Almost there. 2012-10-09 23:33:02 -05:00
Ryan Houdek
8123b137aa This is the terrible bit that can't be removed until we use UBOs in the GLSL shaders. 2012-10-09 23:31:31 -05:00
Ryan Houdek
0fc755c4df More stuff 2012-10-09 23:31:31 -05:00
Ryan Houdek
66a5334158 moe 2012-10-09 23:30:48 -05:00
Ryan Houdek
7a4c080c70 mah 2012-10-09 23:29:30 -05:00
Ryan Houdek
411357b54a Compile 2012-10-09 23:29:30 -05:00
Ryan Houdek
34c7b3fd73 meh 2012-10-09 23:29:30 -05:00
Ryan Houdek
3943840d5c Now CG plays nice with this new stuff. 2012-10-09 23:27:59 -05:00
Ryan Houdek
a357c77257 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).
2012-10-09 23:23:37 -05:00
Pierre Bourdon
3990002250 Optimize JitCache::InvalidateICache by maintaining a "valid blocks" bitset
Most of the InvalidateICache calls are for a 32 bytes block: this is the
number of bytes invalidated by PowerPC dcb*/icb* instructions. Profiling
shows that a lot of CPU time is spent checking if there are any JIT blocks
covered by these 32 bytes (using std::map::lower_bound).

This patch adds a bitset containing the state of every 32 bytes block in
RAM (JIT cached/not JIT cached). Using that, a 32 bytes InvalidateICache
can check in the bitset if any JIT block might be invalidated. A bitset
check is a lot faster than an std::map::lower_bound operation, improving
performance of JitCache::InvalidateICache by more than 100%.

Some practical numbers:

* Xenoblade Chronicles (PAL)
  56.04FPS -> 59.28FPS (+5.78%)
* The Last Story (PAL)
  30.9FPS -> 32.83FPS (+6.25%)
* Super Mario Galaxy (PAL)
  59.76FPS -> 62.46FPS (+4.52%)

This function still takes more time than it should - more optimization in
this area might be possible (specializing for 32 bytes blocks to avoid
useless memcpy, for example).
2012-10-06 01:49:09 +02:00
Pierre Bourdon
8cefcaa94c Implement a simple benchmarking mode which logs FPS to a file
Very useful to compare performance between two builds, check the impact of
a configuration option, etc. FPS log is stored in User/Logs/fps.txt and is
reset each time you launch a game. Only enabled if you check the "Log FPS
to file" option in your graphics settings.

Could be improved a bit: currently logs only every 1s (so you can't really
see small variations), maybe output more infos to the fps.txt like
average/stddev (but Excel/Libreoffice/Google Docs can compute that easily
too).
2012-10-04 05:41:02 +02:00
NeoBrainX
ac2ce8b16e Video_DX11: Remove some redundant code. 2012-09-27 18:15:45 +02:00
NeoBrainX
bb8b5936c0 Revert "Partially revert revision d511b506120c."
This reverts commit 08e06b2293.
2012-09-27 18:15:44 +02:00
Sonicadvance1
8fed3b76c8 If setting videobackend back to null strings, Just set it to the front of the list. Fixes loading game specific INI files that don't load back the "default" video backend which is nothing. 2012-09-25 00:47:37 +00:00
Ryan Houdek
41266129ba Should fix issue 5630. 2012-09-24 17:16:34 -05:00
Ryan Houdek
3229bf824c Should actually load the backend when it changes via game INI 2012-09-23 17:54:23 -05:00
Ryan Houdek
f8f8aea577 Allow the user to set graphics backend from Game INI. Zero GUI option available for setting. 2012-09-23 16:02:11 -05:00
Ryan Houdek
b4ae200d0d This changes a mmap in MemArena so you don't need 786MB of memory free to actually allocate the 1GB memory space in Linux 32bit. I was also running in to this issue in my development. Kudos to plbl4ster to actually taking the time to research this. Closes issue 5625. 2012-09-23 10:08:13 -05:00
sulokuTDCmago
1e174ad31a F-Zero and Phantasy Star Online Memory Card Manager support. Thanks to Ralf from GS Central
Original information:
http://board.gscentral.org/retro-hacking/53093.htm

Signed-off-by: LPFaint99 <lpfaint99@gmail.com>
2012-09-21 21:41:04 -07:00
Pierre Bourdon
208d25c3f5 Revert merges of aram-dma-fixes and memcard-delay
These merges, while in theory improving emulation accuracy, cause issues
in other parts of the emulator based on invalid assumptions. memcard-delay
fixed some of these issues in the EXI memcard code, but several other
problems still exist and I don't have the time to debug that right now.
2012-09-07 01:11:38 +02:00
Scott Moreau
1ffb9ce47e Fix broken build when using SDL from Externals.
The problem here was the logic that detects SDL in the main CMakeLists.txt
is not the same as it is in DolphinWX/CmakeLists.txt to set libraries. When
using SDL from Externals it failed at link time because -lSDL was never set.
This fixes the problem by using the same condition logic to set the libs
as used when detecting SDL in the first place.
2012-09-02 16:53:15 -06:00
kostamarino@hotmail.com
7be4f1f747 Gameconfig ini updates/additions: The Ant Bully, WWE Day of Reckoning 1 & 2, Dream Pinball 3d, Pokepark, Spider-Man: Edge of Time, Spider-Man: SD, Another Code:R, Geist, The Incredibles 2, Skies of Arcadia Legends. 2012-09-02 15:08:16 +03:00