summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosé Fonseca <jfonseca@vmware.com>2009-03-30 18:29:35 +0100
committerJosé Fonseca <jfonseca@vmware.com>2009-03-30 18:29:35 +0100
commitffaff2736f703523a603f758254b682e6e698ae5 (patch)
tree29ef8cb3e9f7745997ae2a1b417d56cbbe7cc276
parent76d43ed4c98c4e5ad23dd342ecf3ed83b35fdcd7 (diff)
python: Cleanup.
-rw-r--r--src/gallium/state_trackers/python/samples/tri.py13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/gallium/state_trackers/python/samples/tri.py b/src/gallium/state_trackers/python/samples/tri.py
index ed72e4383b..d5e9dcd951 100644
--- a/src/gallium/state_trackers/python/samples/tri.py
+++ b/src/gallium/state_trackers/python/samples/tri.py
@@ -134,16 +134,15 @@ def test(dev):
PIPE_FORMAT_X8R8G8B8_UNORM,
width, height,
tex_usage=PIPE_TEXTURE_USAGE_DISPLAY_TARGET,
- )
- _cbuf = cbuf.get_surface()
+ ).get_surface()
+
fb = Framebuffer()
fb.width = width
fb.height = height
fb.nr_cbufs = 1
- fb.set_cbuf(0, _cbuf)
+ fb.set_cbuf(0, cbuf)
ctx.set_framebuffer(fb)
- ctx.surface_clear(_cbuf, 0x00000000)
- del _cbuf
+ ctx.surface_clear(cbuf, 0x00000000)
# vertex shader
vs = Shader('''
@@ -204,8 +203,8 @@ def test(dev):
ctx.flush()
- show_image(cbuf.get_surface())
- #save_image('tri.png', cbuf.get_surface())
+ show_image(cbuf)
+ #save_image('tri.png', cbuf)