Eevee: optimize vertex shader for probe and shadows.
This commit is contained in:
parent
07dd208209
commit
3f1a7aec13
|
@ -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. */
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
in vec3 pos;
|
||||
|
||||
out vec4 vPos;
|
||||
out int face;
|
||||
flat out int face;
|
||||
|
||||
void main() {
|
||||
vPos = vec4(pos, 1.0);
|
||||
|
|
|
@ -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];
|
||||
|
|
|
@ -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);
|
||||
|
|
Loading…
Reference in New Issue