Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(0)  |  Call(0)  |  Derive(0)  |  Import(0)

src/f/l/Flappy-0.3.7/flappy/display3d/scene3d.py   Flappy(Download)
    def setVertexBufferAt(self, locname, vbuffer, offset=0, 
                                        format=VertexBuffer3DFormat.FLOAT_1):
        loc = gl.getAttribLocation(self._current_prog.gl_program, locname)
        gl.bindBuffer(gl.ARRAY_BUFFER, vbuffer.gl_buffer)
 
                                                                str(format))
 
        self._do(gl.bindBuffer, gl.ARRAY_BUFFER, vbuffer.gl_buffer)
        self._do(gl.enableVertexAttribArray, loc)
        self._do(gl.vertexAttribPointer, loc, dimension, tp, False, 
 
        gl.useProgram(0)
        gl.bindBuffer(gl.ARRAY_BUFFER, 0)
        gl.bindBuffer(gl.ELEMENT_ARRAY_BUFFER, 0)
        gl.bindFramebuffer(gl.FRAMEBUFFER, 0)

src/f/l/Flappy-0.3.7/flappy/display3d/vertexbuffer3d.py   Flappy(Download)
    def upload(self, data):
        gl.bindBuffer(gl.ARRAY_BUFFER, self.gl_buffer)
        gl.bufferData(gl.ARRAY_BUFFER, data, gl.STATIC_DRAW)