Commit Graph

1544 Commits

Author SHA1 Message Date
comex d334a9bc23 Fix stack misalignment issues.
- Call ABI_AlignStack even on x86-64.

- Have ABI_AlignStack respect the difference in current alignment
  between the root JIT function, which has a prolog, and
  ProtectFunction thunks, which do not.  This was causing many games
  to crash on start on OS X.  Since this might otherwise mean changing
  the stack pointer before every call...

- Have one prolog/epilog function rather than two (one of which
  definitely did not do what it was thought to do), and make it
  actually work like a normal one, so that the stack frame shows up
  properly in the debugger.  There should be no performance impact.
2013-09-20 16:46:48 -04:00
Pierre Bourdon 86f6e8cc1e Better fix for issue 6614: ISOProperties should store integer settings for PHack booleans. INIFile is stupid, please kill it with fire. 2013-09-18 12:33:57 +02:00
Pierre Bourdon 7aa98a3830 Fix loading of the 'projection hack enabled' gameini setting
Fixes issue 6614.
2013-09-18 12:23:46 +02:00
Ryan Houdek 24a44ecfb8 [ANDROID] Add two new DriverDetails bugs for Adreno. V45 of the driver has broken shader compilation with UBOs in the shaders, this is most likely fixed with V53 found in the Nexus 5. Add a bug for issue surrounding on screentext and doing a glClear after swap causes screen swizzling and zero frames rendered respectively. On the Java side, pass in the dimensions of the screen swapped since there is an issue with Adreno where it rotates the output 90 degrees for some reason. Disable the GLSL shader cache on Android for now due to the inability to cleanly exit the emulator, this tends to cause the cache to get corrupted. All this together fixes rendering with Adreno 3xx GPUs with driver version v14 and above. In particular my Galaxy S4 still resets with this without the root commands, but my HTC Droid DNA and LG G2 is fine. This must be due to particular 'enhancements' that the Samsung kernel has over the other ones. The speed on Adreno has yet to be optimized, so it will most likely be slow still. Faster than the software rasterizer in any case. The ARMJIT is still broken in at this point, so not much fun can be had. 2013-09-18 02:37:10 -05:00
degasus 75f2738f5c VideoCommon: fix ogl lighting bug which happens because of NaN emulation
attn is sometimes very big (eg 1e27), so attn*attn doesn't fit into a float.
So the funny part here is: 0.0 * (1e27*1e27) = 0.0 * Inf = NaN

As the shader compiler is allowed to change the order of multiplications,
this issue isn't fixed completely.
2013-09-16 17:10:19 +02:00
Pierre Bourdon 501eafb407 Overlay local gameinis over global gameinis instead of copying.
Huge megacommit because a lot of things needed to be modified to make this
possible.
2013-09-14 17:46:41 +02:00
NeoBrainX d1e96c7282 Display warning OSD messages when a game ini is overriding any settings. 2013-09-14 06:08:31 +02:00
Pierre Bourdon 91a758b342 Move TextureDecoder.cl from User to Sys 2013-09-14 06:08:30 +02:00
degasus 3fcdf5e25b VideoCommon: use memcmp to compare shader uid 2013-09-11 17:34:23 +02:00
degasus 3ec9f9b64a videoCommon: also reset logicOp on mode switch 2013-09-09 02:30:44 +02:00
Pierre Bourdon 7acee71c0c Move swapModeTable to a local variable, avoids shader uid generation writing to it 2013-09-04 23:23:29 +02:00
Pierre Bourdon 175707739e Move LightingUidData to the LightingShaderGen header 2013-09-04 23:23:29 +02:00
Ryan Houdek 2897619ddb Removal of my terrible idea. 2013-09-02 05:31:48 -05:00
Ryan Houdek 831963616f [Android] Make texture loading/deleting/drawing backend non-specific by making them happen in the backend instead of somewhere else. Just a clean up commit really. 2013-09-02 01:40:05 -05:00
comex 35b8dfbe0c A few more warnings. 2013-09-01 23:33:35 -04:00
degasus 15df7b3445 ogl driverdetails: add flag to disable hacked and pinned memory
pinned memory is broken for index buffers
hacked buffer crashes the amd driver
2013-08-26 19:45:19 +02:00
degasus 1cbc8f8182 sync gpu: check disable flag before volatile
This could be an optimizing as this condition could be moved out of the loop.
So we save an atomic load.
But I don't know if it matters at all
2013-08-24 18:43:07 +02:00
Rodolfo Bogado dbcc677922 Merge remote-tracking branch 'remotes/origin/dx9-ssaa-fix' 2013-08-23 22:43:03 -03:00
Rodolfo Bogado 40243a4fe7 Indentation Fix 2013-08-23 22:28:17 -03:00
Pierre Bourdon 9303b57db1 Refactor VideoCommon/OnScreenDisplay.
Use strings internally, use a multimap and std::function for callbacks (instead
of a flat vector + loop over the vector to find the right callback type), fix
coding style issues. Simplify MainAndroid code a bit.
2013-08-24 02:13:54 +02:00
Pierre Bourdon 367d6dfd65 Add an OSD message when taking screenshots in D3D9/D3D11
Fixes issue 6486.
2013-08-24 01:41:17 +02:00
degasus 7a5374258e ogl: rework DriverDetails framework + detect UBO mesa bug 2013-08-23 10:52:29 +02:00
Ryan Houdek 1eb1ba8c3d Typo + Add Lima to the driverdetails. 2013-08-21 05:41:32 -05:00
Ryan Houdek 1910f5851f Make us capable of supporting driver specific issues(OSS versus official) 2013-08-21 05:34:52 -05:00
Pierre Bourdon a3a4f21284 Remove some spurious endlines at the end of log messages 2013-08-21 00:19:50 +02:00
degasus 814c1c9572 pixelShaderGen: also execute alpha test for always fail with late z test
This should fix issue 6493, but maybe no real issue as this rendering just do nothing
2013-08-19 21:27:54 +02:00
Pierre Bourdon d6fe9c639b Add an OSD message to remind the user if Shader Debugging is enabled
Fixes issue 6497.
2013-08-17 23:48:06 +02:00
Ryan Houdek 7934df3879 Remove a redundant check in the fifo. 2013-08-17 01:27:08 +00:00
Rodolfo Bogado 979718484f Merge branch 'master' of https://code.google.com/p/dolphin-emu into dx9-ssaa-fix 2013-08-15 00:21:28 -03:00
Pierre Bourdon 7622d5b354 Only call SetGenerationMode from BPWritten if the cull mode changed.
Should decrease CPU usage on the GPU thread by a bit in the OGL backend.
2013-08-15 00:26:03 +02:00
Pierre Bourdon 26f58e1ba5 Add an option to enable performance queries in gameini files, disable it by default 2013-08-14 23:16:46 +02:00
Pierre Bourdon ffdd79df36 Move VideoBackendBase from Common to VideoCommon 2013-08-14 23:16:46 +02:00
NeoBrainX 0cd94b5bc7 VertexShaderGen: Cleanup. 2013-08-14 11:47:23 +00:00
Rodolfo Bogado 9e0fc8b42d Merge branch 'master' of https://code.google.com/p/dolphin-emu into dx9-ssaa-fix 2013-08-12 21:32:25 -03:00
NeoBrainX c05aa0141d ShaderGen: Optimize out most function calls for uid generation. 2013-08-12 18:30:42 +02:00
NeoBrainX fe2ca814c5 LightingShaderGen: Use macro magic instead of snprintf. Should fix performance problems. 2013-08-12 18:30:42 +02:00
NeoBrainX 22d9736787 ShaderGen: Static inline everything. 2013-08-12 18:30:42 +02:00
NeoBrainX 69a5a79c03 PixelShaderGen: Optimize shader uid data order. 2013-08-12 18:30:42 +02:00
NeoBrainX 7a1940020d VertexShaderGen: Optimize shader uid data order. 2013-08-12 18:30:41 +02:00
Rodolfo Bogado 5948665cd6 Merge branch 'master' of https://code.google.com/p/dolphin-emu into dx9-ssaa-fix 2013-08-12 10:30:19 -03:00
NeoBrainX 4c22e1264e PixelShaderGen: Do not write depth in pixel shader if depth testing (and thus writing) is not enabled. Should improve performance quite a bit in some cases.
Fixes issue 6474.
2013-08-12 09:33:36 +00:00
Rodolfo Bogado f4000b6b42 Add the ability to force Dual Source Blending in the configuration file.
this way everyone can check if their hardware support this feature in dx9
2013-08-11 18:48:31 -03:00
NeoBrainX eed36cbf78 D3D11: Implement zcomploc for hardware supporting D3D 11.0. 2013-08-09 22:20:35 +02:00
degasus a6fd2c8227 fix lightning for inconsitent config
It's possible to configure to use the vertex color as lightning source without enabling the vertex color at all.
The old implementation will use zero, but it seems to be wrong (prooven by THPS3), more likely is to disable
the lightning and just return the global color.
This fixes THPS3 on OpenGL, but it isn't verifed on hardware
2013-08-07 14:22:15 +02:00
Rachel Bryk a33b1fcdc6 Make hotkeys for togglign IR, AR, efb copies and fog settings configurable. 2013-07-30 05:49:02 -04:00
degasus 4987f89ecc simplify my last commit 2013-07-29 23:26:18 +02:00
degasus d029fc2f9f remove printf in shader uid generation 2013-07-29 20:52:24 +02:00
Ryan Houdek 4aba0135e1 [Android] Qualcomm Swap hack isn't needed anymore due to the new StreamBuffer type. 2013-07-26 21:49:48 -05:00
Ryan Houdek b6e9a75bdf Good Job Windows. Fixes compiling... 2013-07-27 00:53:53 +00:00
Ryan Houdek f786f0f0c6 Remove the broken buffers bug on Mali hardware since it isn't needed anymore using the glBufferData route in the StreamBuffer class. 2013-07-27 00:41:38 +00:00