My machine, apparently, will not draw lists of vertices in a piglet. The following code displays two identical shapes in different positions of the window, one of which uses a list of vertices, and the other uses a straight draw() . The one that is drawn directly displays perfectly, while the list of vertices is not displayed at all.
import pyglet window = pyglet.window.Window() w, h = window.get_size() vl = pyglet.graphics.vertex_list( 4, ('v2i', (100,0, 100,h, 200,h, 200,0)), ('c3B', (255,255,255, 255,0,0, 0,255,0, 0,0,255)) ) @window.event def on_draw(): window.clear() vl.draw( pyglet.gl.GL_QUADS ) pyglet.graphics.draw( 4, pyglet.gl.GL_QUADS, ('v2i', (300,0, 300,h, 400,h, 400,0)), ('c3B', (255,255,255, 255,0,0, 0,255,0, 0,0,255)) ) pyglet.app.run()
This is pyglet 1.1.2 on Ubuntu Lucid using an AMD Radeon HD 6450 card with the latest Catalyst 12.1 driver. I believe that this should be something to do with drivers, etc., because this code worked three years ago on several NVIDIA cards and almost directly from the pyglet documentation. Does anyone know what settings I need for futz, or if a specific version of the driver works correctly?