google / google/shaderc

Shader stage does matter for preprocessing

Open
#1,366 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
2.2k
Forks
445
Avg merge
11h 6m
Merged PRs (30d)
6

Description

https://github.com/google/shaderc/blob/main/libshaderc_util/src/compiler.cc#L468C10-L468C11 claims:

```
// The stage does not matter for preprocessing.
glslang::TShader shader(EShLangVertex);
```

However, glslang does use the language for setting defines in https://github.com/KhronosGroup/glslang/blob/main/glslang/MachineIndependent/Versions.cpp#L642

The result of this mismatch is that `GL_VERTEX_SHADER` is defined for every shader.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.