Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File extensions for external shaders #738

Closed
lexaknyazev opened this issue Oct 4, 2016 · 6 comments
Closed

File extensions for external shaders #738

lexaknyazev opened this issue Oct 4, 2016 · 6 comments

Comments

@lexaknyazev
Copy link
Member

While it's not required to use any specific filename extension for shader files, could we recommend usage of .frag/.vert instead of .glsl?

This could simplify pipeline integration with glslang.

@javagl
Copy link
Contributor

javagl commented Oct 4, 2016

I wasn't aware that a reasonable convention existed here - I've seen glsl, frag/vert, fs/vs, glslv/glslf and others. (And I fell guilty of using glsl as well).

The recommendation to use vert/frag could certainly be mentioned somewhere.

Related: http://stackoverflow.com/q/6432838

@pjcozzi
Copy link
Member

pjcozzi commented Oct 12, 2016

Is this really worth the change? Should glslang integration really drive us to change this when after dozens of implementations, this has not been a concern?

We are making fixes for 1.0.1, but we have to be careful that we just don't put every arbitrary change on the table.

@lexaknyazev
Copy link
Member Author

.glsl file extension prevents tools from knowing shader language grammar until glTF is loaded. Anyway, this could be done later within each API extension (#733).

@pjcozzi
Copy link
Member

pjcozzi commented Dec 24, 2017

Is it worth discussing this as part of KHR_technique_webgl?

@lexaknyazev
Copy link
Member Author

Yeah, we should also ensure that shader sources could be loaded from bufferViews.

@lexaknyazev
Copy link
Member Author

It's been decided that shader files can have any extension.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants