Mesa (gallium-0.1): python: Show call no in image window.
Jose Fonseca
jrfonseca at kemper.freedesktop.org
Mon May 18 15:08:04 UTC 2009
Module: Mesa
Branch: gallium-0.1
Commit: ca2e29ccb4d0113e5834e64bd21b8d347f7ff978
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=ca2e29ccb4d0113e5834e64bd21b8d347f7ff978
Author: José Fonseca <jfonseca at vmware.com>
Date: Wed Mar 25 15:36:51 2009 +0000
python: Show call no in image window.
---
.../state_trackers/python/retrace/interpreter.py | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/src/gallium/state_trackers/python/retrace/interpreter.py b/src/gallium/state_trackers/python/retrace/interpreter.py
index 7a87d6b..c5122c6 100755
--- a/src/gallium/state_trackers/python/retrace/interpreter.py
+++ b/src/gallium/state_trackers/python/retrace/interpreter.py
@@ -54,14 +54,14 @@ def save_image(filename, surface):
outimage = make_image(surface)
outimage.save(filename, "PNG")
-def show_image(surface):
+def show_image(surface, title):
outimage = make_image(surface)
import Tkinter as tk
from PIL import Image, ImageTk
root = tk.Tk()
- root.title('background image')
+ root.title(title)
image1 = ImageTk.PhotoImage(outimage)
w = image1.width()
@@ -609,7 +609,8 @@ class Interpreter(parser.TraceDumper):
filename = '%s_%04u.png' % (description, self.call_no)
save_image(filename, surface)
else:
- show_image(surface)
+ title = '%u. %s' % (self.call_no, description)
+ show_image(surface, title)
class Main(parser.Main):
More information about the mesa-commit
mailing list