Commit Graph

10 Commits

Author SHA1 Message Date
Mark Satterthwaite
83ad7e246f Implemented desktop OpenGL support for GL_ARB_separate_shader_objects without requiring any additional shader platforms to reduce shader compile/link hitches.
- Shaders which emit layout location data use INTERFACE_LOCATION & INTERFACE_BLOCK macros to defer to the runtime whether they can be used as separable or non-separable shaders.
- The runtime supplies the correct #define for each so that the shaders still work on platforms where the glLinkProgram implementation fails with separable shader code.
- Shader model 5 platforms (GLSL 430 or ES 3.10) which were already specifying & using layout location data continue to do so, even when using glLinkProgram.
- The 'OpenGL.UseSeparateShaderObjects' console variable allows switching between SSO/Link modes between executions, but not dynamically at runtime.
- Only defaults to on for Mac as that is the only platform which can guarantee that the extension is always available & so far the most tested platform.
- Updated hlslcc binaries are supplied for Mac, Linux & Windows.
- Added an OpenGL RHI stat for shader first draw time so that it is easy to see why hitches occur during runtime due to in-driver shader compilation.

reviewedby michael.trepka, nick.penwarden, dmitry.rekman, rolando.caloca

[CL 2435530 by Mark Satterthwaite in Main branch]
2015-02-06 11:35:30 -05:00
Mark Satterthwaite
28441d4127 Fix-up the .w component for gl_FragCoord being used as SV_Position - it would appear that they aren't the same (GL claims 1/clip.w, presumably from the usage in our shaders D3D provides clip.w).
#codereview michael.trepka, rolando.caloca, nick.penwarden, gil.gribb

[CL 2387119 by Mark Satterthwaite in Main branch]
2014-12-12 12:30:21 -05:00
Ben Marsh
149375b14b Update copyright notices to 2015.
[CL 2379638 by Ben Marsh in Main branch]
2014-12-07 19:09:38 -05:00
Rolando Caloca
7311f61f67 UE4 - hlslcc - Move mem barrier/sync functions out of core hlslcc and into GLSL backend
[CL 2356437 by Rolando Caloca in Main branch]
2014-11-11 17:28:52 -05:00
Rolando Caloca
1e13c6f58a UE4 - hlslcc - Rollback //depot/UE4/Engine/Source/ThirdParty/hlslcc to changelist 2316264
[CL 2319202 by Rolando Caloca in Main branch]
2014-10-03 20:02:42 -04:00
Rolando Caloca
7fb711f19c UE4 - hlslcc - Final set of warnings/fixes before moving to Engine
[CL 2318665 by Rolando Caloca in Main branch]
2014-10-03 11:45:34 -04:00
Rolando Caloca
3c62d97a9c UE4 - Fix Mac shader compile times
#codereview Michael.Trepka, Peter.Sauerbrei

[CL 2318603 by Rolando Caloca in Main branch]
2014-10-03 11:10:23 -04:00
Rolando Caloca
b61809b923 UE4 - Mac compile fixes
[CL 2316687 by Rolando Caloca in Main branch]
2014-10-01 18:16:34 -04:00
Rolando Caloca
3fd8c0b1d3 UE4 - hlslcc - Move files out from mesa
[CL 2315208 by Rolando Caloca in Main branch]
2014-09-30 18:44:44 -04:00
Rolando Caloca
f95c834450 UE4 - Rename ir_gen_glsl.* to GlslBackend.*
- Fix some warnings

[CL 2310427 by Rolando Caloca in Main branch]
2014-09-25 18:03:18 -04:00