Jason Ekstrand
f3d70e4165
vk/glsl_scraper: Use the LunarG back-door for GLSL source
2015-05-21 12:22:44 -07:00
Jason Ekstrand
cb56372eeb
vk/glsl_scraper: Use a fake GLSL version that glslang will accept
2015-05-21 12:21:02 -07:00
Jason Ekstrand
0e441cde71
vk: Bake the GLSL_VK_SHADER macro into the scraper output file
2015-05-21 12:21:00 -07:00
Jason Ekstrand
e37a89136f
vk/glsl_scraper: Add a --glsl-only option
2015-05-19 11:29:07 -07:00
Jason Ekstrand
4bcf58a192
vk/glsl_scraper: Use the line number from the end of the macro
...
We used to use the line number from the start of the macro but this doesn't
seem to match the c preprocessor
2015-05-19 11:29:07 -07:00
Jason Ekstrand
1573913194
vk/glsl_scraper: Don't open files until needed
...
This prevents us from writing an empty file when the compile failed.
2015-05-19 11:29:07 -07:00
Jason Ekstrand
41db8db0f2
vk: Add a GLSL scraper utility
...
This new utility, glsl_scraper.py scrapes C files for instances of the
GLSL_VK_SHADER macro, pulls out the shader source, and compiles it to
SPIR-V. The compilation is done using glslValidator. The result is then
placed into another C file as arrays of dwords that can be easiliy handed
to a Vulkan driver.
2015-05-14 19:18:57 -07:00