- Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathblur.py
More file actions
Latest commit
21 lines (14 loc) · 365 Bytes
/
Copy pathblur.py
File metadata and controls
21 lines (14 loc) · 365 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
importpixie
image=pixie.Image(200, 200)
image.fill(pixie.Color(1, 1, 1, 1))
trees=pixie.read_image("examples/data/trees.png")
path=pixie.Path()
path.polygon(100, 100, 70, 6)
mask=pixie.Mask(200, 200)
mask.fill_path(path)
blur=trees.copy()
blur.blur(20)
blur.mask_draw(mask)
image.draw(trees)
image.draw(blur)
image.write_file("examples/blur.png")