fd637030e4
GeometryShaderGen: Consistently use xfmem just as the vertex shader.
...
There are very rare conditions in which xfmem can actually desync from bpmem.
2015-06-10 16:13:54 +02:00
4cbaddb7ad
GeometryShaderGen: Don't use centroid in
for input variables.
2015-06-10 16:04:32 +02:00
30ebb2459e
Set copyright year to when a file was created
2015-05-25 13:22:31 +02:00
cefcb0ace9
Update license headers to GPLv2+
2015-05-25 13:22:31 +02:00
8c55ec0d51
GeometryShaderGen: Perspective divide the line coordinates before comparing the angle.
2015-01-31 23:32:23 +01:00
1b771deb56
Move worldpos into it's own varying.
...
Previously it was packed into spare slots in clippos.xy and normal.w,
but it's ugly and more importantly it's causing bugs.
This was discovered during the debugging of a zfreeze branch, which
expected clippos.xy to be xy position coordinates in clipspace (as
the name suggested).
Turns out the stereoscopy shader had also run into this trap, modifying
clippos.x (introducing errors with per-pixel lighting).
This commit has been moved outside of the zfreeze PR for fast merging.
2015-01-03 09:23:09 +13:00
7eb353b3bd
VideoCommon: Don't pass structs between shaders, use the interface blocks instead.
2014-12-28 23:28:00 +01:00
a560d8f150
Merge pull request #1716 from Armada651/geom-wireframe
...
VideoCommon: Handle wireframe mode in the geometry shader.
2014-12-20 12:22:40 +01:00
0d79e8f32b
VideoCommon: Don't specify the redundant in/out qualifier if GL_ARB_shading_language_420pack is supported.
...
Some driver developers interpreted "can" as "must" in the OpenGL specs. (I'm looking at you AMD)
2014-12-19 22:45:39 +01:00
531b3941ff
GeometryShaderGen: Re-emit the first vertex when wireframe mode is enabled.
2014-12-19 14:24:08 +01:00
1b9fe70d7c
VideoCommon: Make IsPassthrough() a function of the ShaderUid.
2014-12-19 14:10:53 +01:00
925bbcb85b
VideoCommon: Handle wireframe mode in the geometry shader.
2014-12-19 14:10:52 +01:00
cdd9e07522
VideoCommon: Add in/out qualifiers to centroid storage qualifier.
...
Fixes shaders for GPUs that don't support GL_ARB_shading_language_420pack.
2014-12-19 12:19:15 +01:00
e7e8a4f1cb
GeometryShaderGen: Don't use the reserved keyword "point" in D3D.
2014-12-19 02:24:41 +01:00
782a5adb94
VideoCommon: Pass interface blocks between shader stages to resolve naming conflicts.
2014-12-18 00:36:49 +01:00
bd6d229733
GeometryShader: Disable the geometry shader stage if it is a pass-through shader.
2014-12-18 00:36:48 +01:00
f2e52b46c3
GeometryShaderGen: Cosmetics.
2014-12-18 00:36:47 +01:00
0ac7103391
GeometryShaderGen: Pack uniforms more tightly.
2014-12-18 00:36:40 +01:00
d115048615
GeometryShaderGen: Remove redundant declaration.
2014-12-15 23:20:56 +01:00
16af00d515
GeometryShaderGen: Use signed integers for the texture offset flags.
2014-12-15 23:05:16 +01:00
861fa1af23
GeometryShaderGen: Declare a prototype for EmitVertex().
2014-12-15 22:47:43 +01:00
8ae738ff30
VideoCommon: Merge PointGeometryShader into GeometryShaderGen.
...
This adds point-width emulation support to OpenGL.
2014-12-15 22:47:43 +01:00
55e60a9c22
VideoCommon: Merge LineGeometryShader into GeometryShaderGen.
...
This adds line-width emulation support to OpenGL.
2014-12-15 22:47:42 +01:00
382e1c22db
GeometryShaderGen: Support multiple primitive types.
...
And make more stereoscopy code optional.
2014-12-15 22:47:41 +01:00
887c669c28
GeometryShaderGen: Redefine gl_InvocationID so we can use the same variable name in both backends.
2014-12-15 22:47:40 +01:00
332ba4b210
GeometryShaderManager: Upload Line/Point width constants.
2014-12-15 22:47:35 +01:00
aa4242fd9c
GeometryShaderGen: Pass the primitive type and always run the generator regardless of stereoscopy.
2014-12-14 21:23:20 +01:00
b406e4e1f2
VideoCommon: Add a separate constants buffer for the geometry shader.
2014-12-14 21:23:13 +01:00
cec5b0ce01
ShaderGen: Remove the GS_OUTPUT struct for OpenGL.
...
And remove the generator for it since it is no longer used outside of the geometry shader.
2014-12-14 13:28:50 +01:00
ea2bcb44f0
Cosmetics
2014-12-14 13:28:48 +01:00
4f6ce0f236
D3D: Add geometry shader instancing support.
2014-12-14 13:28:44 +01:00
9253bb7d96
D3D: Add geometry shader stereoscopy support.
2014-12-14 13:28:41 +01:00
d5ebdf7a97
D3D: Add GeometryShaderCache.
2014-12-14 13:28:41 +01:00
9bcadc8029
Common: Remove locale based functions from CommonFuncs.
...
Since %f isn't used anymore in the shader generators, these can go.
2014-12-05 20:55:29 -05:00
9b2cd82da5
GeometryShaderGen: Set the properties of the VS_OUTPUT struct in the uid.
2014-11-23 14:30:12 +01:00
ed9f258b27
GeometryShader: Don't read from output variables
2014-11-23 14:30:12 +01:00
106df04e8e
GeometryShaderGen: Declare the vertex array size.
2014-11-23 14:30:12 +01:00
422125c1a9
GeometryShaderGen: Add comments.
2014-11-23 14:30:12 +01:00
f3ddf37d07
VideoCommon: Switch to Nvidia stereoscopy offset formula.
2014-11-23 14:27:40 +01:00
27f3f804a0
ShaderGen: Only pass VS_OUTPUT between shaders if stereo 3D is enabled.
...
GLSL130 doesn't support passing structs between shaders.
This is not a problem for stereo 3D which has a GLSL150 requirement.
2014-11-23 14:27:40 +01:00
51a4d6a4be
GeometryShader: Adjust positions after projection.
...
By adjusting the positions in clip space we can avoid the re-projection.
2014-11-23 14:27:40 +01:00
acc65ee608
GeometryShader: Replicate missing position manipulations from vertex shader.
2014-11-23 14:27:40 +01:00
d7804a4d3e
Cosmetics.
2014-11-23 14:27:39 +01:00
9b22e15180
VideoConfigDiag: Add stereoscopy options group.
2014-11-23 14:27:38 +01:00
4d9589b35f
Cosmetics.
2014-11-23 14:27:38 +01:00
f370cb386c
ProgramShaderCache: Always generate a geometry shader UID, even if stereoscopy is disabled.
2014-11-23 14:27:38 +01:00
6cacfad010
GeometryShader: Transform the projection within the geometry shader.
...
Reduces the amount of data transferred through uniforms.
The shearing transformation is reduced to a single multiplication/addition for optimization.
2014-11-23 14:27:38 +01:00
63b37e29d1
ShaderGen: Rename "eye" to "layer".
...
Keeping things generic.
2014-11-23 14:26:56 +01:00
d583720a59
GeometryShaderGen: Support stereoscopy on GPUs without support for instancing.
2014-11-23 14:26:56 +01:00
176191dc16
ShaderGenCommon: Move uniforms into a common static string.
2014-11-23 14:24:09 +01:00