Eevee: optimize vertex shader for probe and shadows.

This commit is contained in:
Clément Foucault 2017-05-19 12:00:20 +02:00
parent 07dd208209
commit 3f1a7aec13
4 changed files with 4 additions and 4 deletions

View File

@ -5,7 +5,7 @@ layout(triangle_strip, max_vertices=3) out;
uniform int Layer;
in vec4 vPos[];
in int face[];
flat in int face[];
out vec3 worldPosition;
out vec3 worldNormal; /* Required. otherwise generate linking error on AMD. */

View File

@ -2,7 +2,7 @@
in vec3 pos;
out vec4 vPos;
out int face;
flat out int face;
void main() {
vPos = vec4(pos, 1.0);

View File

@ -8,7 +8,7 @@ layout(std140) uniform shadow_render_block {
};
in vec4 vPos[];
in int face[];
flat in int face[];
void main() {
int f = face[0];

View File

@ -4,7 +4,7 @@ uniform mat4 ShadowModelMatrix;
in vec3 pos;
out vec4 vPos;
out int face;
flat out int face;
void main() {
vPos = ShadowModelMatrix * vec4(pos, 1.0);