]> git.tdb.fi Git - libs/gl.git/commitdiff
Fix an index mismatch between setting attribute array pointers and enabling the arrays
authorMikko Rasa <tdb@tdb.fi>
Fri, 16 Jan 2009 09:05:12 +0000 (09:05 +0000)
committerMikko Rasa <tdb@tdb.fi>
Fri, 16 Jan 2009 09:05:12 +0000 (09:05 +0000)
source/vertexarray.cpp

index ef11844466b9ff7833dcde88a53a69ff422f059d..6740818e794228e78ebedbbc880855aa3abcb33c 100644 (file)
@@ -120,7 +120,7 @@ void VertexArray::apply() const
        set_array(GL_TEXTURE_COORD_ARRAY, found&4, 4);
        set_array(GL_COLOR_ARRAY, found&8, 8);
        for(unsigned i=4; i<32; ++i)
-               set_array(i-3, (found>>i)&1, 1<<i);
+               set_array(i-4, (found>>i)&1, 1<<i);
 
        if(vbuf)
                VertexBuffer::unbind();