https://github.com/shader-slang/slang
Revision 6da1782f34e8022774dce8d253bc5c3ab9b496cc authored by Tim Foley on 07 July 2017, 03:47:20 UTC, committed by Tim Foley on 07 July 2017, 17:00:25 UTC
GLSL doesn't support `static` at all, while HLSL uses it for multiple things:

- To mark global variables that are "thread local" rather than shader parameters
- In the C/C++ style to mark `static` allocation for variables inside a function or type

The latter case needs to be handled during lowering (but isn't handled right now).
The former case can be solved just by dropping the `static` keyword.
1 parent 4921bdb
History
Tip revision: 6da1782f34e8022774dce8d253bc5c3ab9b496cc authored by Tim Foley on 07 July 2017, 03:47:20 UTC
Don't emit the `static` keyword when generating GLSL
Tip revision: 6da1782
File Mode Size
build
examples
external
source
tests
tools
.gitignore -rw-r--r-- 247 bytes
.gitmodules -rw-r--r-- 107 bytes
LICENSE -rw-r--r-- 1.1 KB
README.md -rw-r--r-- 1.5 KB
appveyor.yml -rw-r--r-- 1.5 KB
slang.h -rw-r--r-- 28.8 KB
slang.sln -rw-r--r-- 6.3 KB
test.bat -rw-r--r-- 1.4 KB

README.md

back to top