Posts

Showing posts with the label glsl

Glslang shader “header” file naming conventions

Glslang shader “header” file naming conventions For typical shader stages glslang enforces the naming conventions *.vert , *.tesc , *.tese , *.geom , *.frag , *.comp which let you compile your shaders to Spir-V without specifying the -S flag. *.vert *.tesc *.tese *.geom *.frag *.comp -S However what about "header" files with common functions that you may include inside many shaders for multiple different stages using the GL_GOOGLE_include_directive extension? GL_GOOGLE_include_directive Obviously people are free to name them however they want but are there some reasonable conventions that have emerged? I can't find an extension specification for that extension anywhere online. So I'm not sure how it could be widely used enough for "some reasonable conventions" to emerge. – Nicol Bolas Jul 2 at 2:01 ...