|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+#!/usr/bin/python3
|
|
|
2
|
+
|
|
|
3
|
+import cairo
|
|
|
4
|
+import math
|
|
|
5
|
+
|
|
|
6
|
+img = cairo.ImageSurface(cairo.FORMAT_ARGB32, 256, 256)
|
|
|
7
|
+cx = cairo.Context(img)
|
|
|
8
|
+cx.set_source_rgb(0.125, 0.125, 0.125)
|
|
|
9
|
+cx.paint()
|
|
|
10
|
+
|
|
|
11
|
+cx.set_source_rgb(0.25, 0.25, 0.25)
|
|
|
12
|
+
|
|
|
13
|
+for i in range(1, 8):
|
|
|
14
|
+ num = 2 ** i
|
|
|
15
|
+ for j in range(0, num + 1):
|
|
|
16
|
+ x = float(j) * 256.0 / num
|
|
|
17
|
+ w = 8.0 / num
|
|
|
18
|
+ cx.rectangle(x - w * 0.5, 0, w, 256)
|
|
|
19
|
+ cx.rectangle(0, x - w * 0.5, 256, w)
|
|
|
20
|
+
|
|
|
21
|
+cx.fill()
|
|
|
22
|
+
|
|
|
23
|
+img.write_to_png('no_tile.png')
|