[Impeller] Match position attribute name across runtime effect stages (flutter/engine#39552)

This commit is contained in:
Brandon DeRosier
2023-02-16 13:06:48 -08:00
committed by GitHub
parent 7e60a47eea
commit 327c0dfeaa
2 changed files with 8 additions and 2 deletions

View File

@@ -7,6 +7,9 @@
#if defined(IMPELLER_GRAPHICS_BACKEND)
// Note: The GLES backend uses name matching for attribute locations. This name
// must match the name of the attribute output in:
// impeller/entity/shaders/runtime_effect.vert
in vec2 _fragCoord;
vec2 FlutterFragCoord() {
return _fragCoord;

View File

@@ -10,9 +10,12 @@ uniform VertInfo {
vert_info;
in vec2 position;
out vec2 v_position;
// Note: The GLES backend uses name matching for attribute locations. This name
// must match the name of the attribute input in:
// impeller/compiler/shader_lib/flutter/runtime_effect.glsl
out vec2 _fragCoord;
void main() {
gl_Position = vert_info.mvp * vec4(position, 0.0, 1.0);
v_position = position;
_fragCoord = position;
}