Branch
Hash :
ded8ecc0
Author :
Date :
2025-10-15T15:26:23
Translator: Handle GS and TES output gl_Position like VS
The spec declares these special shader variables identically as:
```
out gl_PerVertex {
highp vec4 gl_Position;
};
```
Between vertex, geometry and tessellation evaluation shaders. Since the
output is nameless, vertex shaders have always treated `gl_Position` as
if it's a variable on its own. In this change, TES and GS treat that
variable the same way.
Additionally, this change removes `gl_Position` as a standalone variable
from tessellation _control_ shaders, which must always use `gl_out`
instead.
Bug: angleproject:349994211
Change-Id: Ib33592fb62af31021a99f76f77c27da214425826
Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/7042770
Auto-Submit: Shahbaz Youssefi <syoussefi@chromium.org>
Reviewed-by: Yuxin Hu <yuxinhu@google.com>
Commit-Queue: Shahbaz Youssefi <syoussefi@chromium.org>
{
"src/compiler/translator/ImmutableString_autogen.cpp":
"bdca088e715535c1295807cfad85cb43",
"src/compiler/translator/Operator_autogen.h":
"5bf164c0e357df73ab727dd14346f05e",
"src/compiler/translator/SymbolTable_autogen.cpp":
"263514aaf841cf51662cd4674a6828ba",
"src/compiler/translator/SymbolTable_autogen.h":
"19c89d6aeb66297b95c9751c56bcc455",
"src/compiler/translator/builtin_function_declarations.txt":
"df755020e057b626d8a8412bb481bea8",
"src/compiler/translator/builtin_variables.json":
"e82370e17b9f1aa8fea98dbc0d474753",
"src/compiler/translator/gen_builtin_symbols.py":
"868aec3ab57d9d487b66afc7ac454ba7",
"src/compiler/translator/tree_util/BuiltIn_autogen.h":
"5411d1744f488e5f591bcbeb10d76cc8",
"src/tests/compiler_tests/ImmutableString_test_autogen.cpp":
"5042b7aad8ef26523f4b6a6d08e96b55"
}