Sign in to follow this  
Followers 0
ic0de

sharing vertex attributes between shaders

1 post in this topic

I have several shaders that share a common set of vertex attributes and I was wondering if it was possible to share the index of a vertex attrib array between two or more shaders so that I don't need to bind a different vertex attrib array for each different shader I use. Edited by ic0de
0

Share this post


Link to post
Share on other sites
I use glBindAttribLocation on all my shaders to force attributes into known slots. You have to call it before linking your program.
1

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0