Commit Graph

71 Commits

Author SHA1 Message Date
f43d85921d VideoBackends: Add AbstractStagingTexture class
Can be used for asynchronous readback or upload of textures.
2017-11-22 18:47:04 +10:00
49a9c33bd7 VideoCommon: Move abstract texture creation function to Renderer 2017-11-22 18:47:04 +10:00
53684701fa HybridXFB: Fix lint errors 2017-11-17 22:11:31 -06:00
33bc286baa Remove old XFB logic 2017-11-17 22:11:29 -06:00
a9f0d1783b Support frame and video dumping from VideoCommon 2017-11-17 22:11:23 -06:00
79387dddb2 Add support for hybrid XFB 2017-11-17 19:47:56 -06:00
24ddea04ce VideoBackends: Move SamplerState to common 2017-09-11 20:01:54 +10:00
836b9b9acb Renderer: Move cull mode to a rasterization state object
Also moves logic for primitive handling to VideoCommon.
2017-09-11 20:01:45 +10:00
2869c570f1 Renderer: Move depth state to VideoCommon and seperate from bpmem 2017-09-11 19:40:26 +10:00
3dd675e613 Renderer: Change SetBlendState to accept a BlendingState
This decouples the state generation (from the emulated GPU) from the
management of internal backend state.
2017-09-03 14:14:54 +10:00
cd502990fa OGL: Uber shader support 2017-07-30 17:43:59 +10:00
abc662d69c OGL: Support compute shaders and emitting GLSL 4.3
This also changes bSupportsEarlyFragmentTests to
bSupportsImageLoadStore, as it is used for both.
2017-04-01 12:31:41 +10:00
a8876a29fe OGL: Use ARB_texture_storage to allocate TextureCache entries
This ensures that they are complete textures by decoding time, as when
using compute shaders we write directly to the destination texture.
2017-04-01 12:31:41 +10:00
2cd240af0d VideoBackends: Move max texture size to VideoConfig
This stops the virtual method call from within the Renderer constructor.

The initialization here for GL had to be moved to VideoBackend, as the
Renderer constructor will not have been executed before the value is
required.
2017-03-10 00:04:13 +10:00
238a70b006 VideoCommon: Move some common initialization logic to RenderBase 2017-03-04 16:42:16 +10:00
277829d842 VideoCommon: Eliminate static state in Renderer 2017-03-04 16:39:50 +10:00
70cf774a5c RenderBase: Forward declare EFBAccessType 2017-01-23 12:41:26 -05:00
23b0faeba5 OGL: Use VideoCommon blend state for framebuffer configuration. 2017-01-06 14:01:39 +01:00
607ce40f0b OGL: Fix black screen when MSAA is enabled 2016-12-12 17:51:19 +10:00
b81dee8b9a OGL: Support full-resolution frame dumping 2016-11-28 21:54:56 +10:00
93221e7f48 OGL: Move frame rendering procedures to seperate methods 2016-11-28 21:54:56 +10:00
741debe229 OGL: Avoid reallocation of frame dumping PBO. 2016-11-07 22:32:54 +01:00
f6a6cc9c67 OGL: Use PBO for framedump, with async readback. 2016-11-07 22:17:32 +01:00
9f264c0872 AVIDump: Move CoreTiming into caller. 2016-10-10 12:03:18 +02:00
64927a2f81 Renderer: Merge screenshot logic into VideoCommon. 2016-10-08 19:38:57 +02:00
86112c7258 VideoCommon: Minor changes
Make Renderer::GetMaxTextureSize return u32 instead of int.
2016-10-03 06:51:46 -07:00
6a99cbd9fc VideoCommon: Call Renderer::SurfaceChanged on render parent resize
This is needed because for some reason the WSI for NV Vulkan drivers
doesn't return VK_ERROR_OUT_OF_DATE_KHR, so there is no other way to know
that a resize has occured apart from polling, which is a poor solution for
X11 (since it is blocking).
2016-10-01 01:09:12 +10:00
da0204a85c Fix a really stupid GLSL version parsing bug 2016-08-19 08:53:27 -04:00
3570c7f03a Reformat all the things. Have fun with merge conflicts. 2016-06-24 10:43:46 +02:00
c34fb3edf0 Use ffmpeg for Windows Video Dumping instead of VFW 2016-01-07 18:37:58 -05:00
b4e9bbb551 Merge pull request #3336 from Sonicadvance1/improve_glextensions
[GLExtensions] Improve the extension loader.
2016-01-01 13:01:51 -05:00
a61fc372bb VideoCommon: Change PokeEFB to take a pointer rather than a vector
This saves allocating a vector for the pass-through path.
2015-12-20 14:42:14 +10:00
78dda1cf79 [OGL] Update extension checks in Render.
This was relying on behaviour that GLExtensions was adding fake extensions to the supported list with ES.
This no longer happens so it needed to be changed.
2015-12-13 11:39:45 -06:00
df799dd124 VideoCommon: Create default implementation for state setters
It's fine to pull those within the backends, so there is no need to enforce them to implement this interface.
2015-11-24 22:39:10 +01:00
ed5e3c054e Enable Anisotropic filtering in ES.
This adds a check to make sure the vendor supports anisotropic filtering.
Pretty much all vendors support this, even the mobile ones.
2015-11-19 02:00:43 -06:00
51c984dde3 Remove the "Show EFB Copy Regions" debug option.
It was only implemented in OpenGL, though the option was visible in both
backends, leading to memory leaks if you enabled it in DirectX.

And it wasn't particularly useful as a debug feature as it only showed
where in the EFB the copies were taken from, not what format it was, or
what the copy was used for, or what content was in the EFB at that point
in time.

Also, it stretched the copy regions relative to the window, so the
on-screen regions don't even line up with the window unless the game used
the full EFB (some pal games) and you game image stretched to the full
window.
2015-11-05 18:15:46 +13:00
e7b2a22225 Support Conservative Depth as a fallback for EarlyZ
Allows Mesa based drivers to support ZCompLoc
2015-10-18 01:46:54 +13:00
1c0366993a VideoBackends: Reimplement SSAA, now for D3D + OGL 2015-09-06 19:40:00 +02:00
7650117c26 Properly support MSAA and SSAA as separate features(+GLES)
SSAA relies on MSAA being active to work. We only supports 4x SSAA while in fact you can enable SSAA at any MSAA level.
I even managed to run 64xMSAA + SSAA on my Quadro which made some pretty sleek looking games. They were very cinematic though.

With this, it properly fixes up SSAA and MSAA support in GLES as well. Before they were broken when stereo rendering was enabled.
Now in GLES they can properly support MSAA and also stereo rendering with MSAA enabled(with proper extensions).
2015-09-05 05:23:29 -05:00
7a35f9285b [GLES] Support texture_buffer for palette texture conversion.
OpenGL ES 3.2 adds this feature to core
It was available to GLES 3.1 as GL_{EXT, OES}_texture_buffer as well.
For the non-Nvidia vendors that implemented this is:
      - Qualcomm's Adreno 4xx
      - IMGTec's PowerVR Rogue
2015-09-01 05:41:03 -05:00
447b1b09e3 Support OpenGL ES 3.2.
OpenGL ES 3.2 adds a few things we care about supporting in core. In particular:
- GL_{ARB,EXT,OES}_draw_elements_base_vertex
- KHR_Debug
- Sample Shading
- GL_{ARB,EXT,OES,NV}_copy_image
- Geometry shaders
- Geometry shader instancing (If they support GL_{EXT,OES}_geometry_point_size)

Nvidia was the first to release an OpenGL ES 3.2 driver which I uesd to test this on.
This also enables GS Instancing on GLES 3.1 hardware if it supports all of the required extensions.
2015-08-26 17:57:51 -05:00
e2f42f8fd0 OGL: Move copy_image variable into backend. 2015-08-06 19:41:36 +02:00
8cc271516d Revert "Revert "OGL: Change the depth buffer type to GL_FLOAT.""
This reverts commit 05d60f4fef.
2015-06-06 20:09:22 +02:00
dad5d8e13d Merge pull request #2357 from degasus/ogl_efb_poke_merge
ogl: efb poke merge
2015-05-25 23:26:39 -04:00
268f52e054 Add missing license headers 2015-05-25 13:11:47 +02:00
05d60f4fef Revert "OGL: Change the depth buffer type to GL_FLOAT."
This reverts commit 4b2e04b862.
2015-05-20 14:22:29 +02:00
d91d935057 OGL: reimplement poke-color 2015-05-20 11:05:31 +02:00
4b2e04b862 OGL: Change the depth buffer type to GL_FLOAT. 2015-05-08 14:29:29 +02:00
35373c5185 TextureCache: load all mipmap levels from custom textures
This drops the "feature" to load level 0 from the custom texture
and all other levels from the native one if the size matches.
But in my opinion, when a custom texture only provide one level,
no more should be used at all.
2015-03-02 00:09:09 +01:00
1ed41672f5 OGL: disable driver warnings fetch
This did give a decent slowdown on some drivers.
2014-12-28 22:31:24 +01:00