def assign_vertex_attrib_location(self, vbo, location):
        """Load data into a vbo"""
        with vbo:
            if self.n_verts:
                assert vbo.data.shape[0] == self.n_verts
            else:
                self.n_verts = vbo.data.shape[0]

            # vbo.buffer_data()
            gl.glVertexAttribPointer(location, vbo.data.shape[1], gl.GL_FLOAT, gl.GL_FALSE, 0, 0)
            gl.glEnableVertexAttribArray(location)
def assign_vertex_attrib_location ( self , vbo , location ) : with vbo : if self . n_verts : assert vbo . data . shape [ 0 ] == self . n_verts else : self . n_verts = vbo . data . shape [ 0 ] gl . glVertexAttribPointer ( location , vbo . data . shape [ 1 ] , gl . GL_FLOAT , gl . GL_FALSE , 0 , 0 ) gl . glEnableVertexAttribArray ( location )
Load data into a vbo