opengl - glBindAttribLocation index 0 -



opengl - glBindAttribLocation index 0 -

when seek bind attribute index of 0, shader programme fails @ linking , info infolog gives is:

vertex shader(s) failed link, fragment shader(s) linked.

according the opengl docs

this command makes possible vertex shaders utilize descriptive names attribute variables rather generic variables numbered 0 gl_max_vertex_attribs -1.

so binding attribute index 0 should work. though not important, curious why cannot bind attribute index 0. suggestions welcome.

quoting op commentary, because saved me:

i found problem(this causing other problems): in vertex shader had switched using gl_vertex using own attribute, "vertex", @ 1 place in shader had forgotten alter variable name, , since gl_vertex uses 0 index...

opengl

Comments

Popular posts from this blog

iphone - Dismissing a UIAlertView -

c# - Can ProtoBuf-Net deserialize to a flat class? -

javascript - Change element in each JQuery tab to dynamically generated colors -