GLSL着色器文件扩展名
规范中没有正式的扩展。OpenGL不处理从文件中加载着色器;您只是将着色器代码作为字符串传递,因此没有特定的文件格式。
Khronos的参考GLSL编译器/验证器使用以下扩展来确定文件用于哪种类型的着色器:
.vert
- a vertex shader.tesc
- a tessellation control shader.tese
- a tessellation evaluation shader.geom
- a geometry shader.frag
- a fragment shader.comp
- a compute shader
相关参考
opengl - What is the correct file extension for GLSL shaders? - Stack Overflow