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

More flexible shader name matching #146

Open
c42f opened this issue Oct 7, 2016 · 1 comment
Open

More flexible shader name matching #146

c42f opened this issue Oct 7, 2016 · 1 comment
Labels

Comments

@c42f
Copy link
Owner

c42f commented Oct 7, 2016

The case of variable names can cause a mismatch between variables in the file and variables in the shader. This is a bit of an unnecessary pain, and it would be useful if we were a bit more flexible about how the matching worked. For robustness and flexibility the name matching could be a two stage process:

  1. Match names exactly if possible, including perfect case matching etc
  2. If no match is found, attempt to match by normalizing to all lowercase, (possibly also removing underscores, etc?)
@c42f c42f added the api label Oct 7, 2016
@devshgraphicsprogramming

I would advise to abandon matching shader inputs to variable names with C++

This has been made obsolete with the layout qualifier
https://www.khronos.org/opengl/wiki/Layout_Qualifier_(GLSL)

Since you've migrated to OpenGL 3.3 you can forego the use of most name-based-interface-matching

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

No branches or pull requests

2 participants