【发布时间】:2017-01-18 20:32:27
【问题描述】:
我知道如何画圆,但不会画圆弧
from PIL import Image, ImageDraw
img = Image.new("RGB",(60,60),'white')
dr = ImageDraw.Draw(img)
dr.ellipse((0,0,60,60),'yellow','black')
现在我明白了,谢谢你的帮助..
from PIL import Image
from PIL import ImageDraw
image = Image.new('RGB',(90,90),'white')
draw = ImageDraw.Draw(image)
draw.ellipse((0,0,90,90),'yellow','blue')
draw.ellipse((25,20,35,30),'yellow','blue')
draw.ellipse((50,20,60,30),'yellow','blue')
draw.arc((20,40,70,70), 0, 180, 0) #draw circle in black
image.show()
【问题讨论】:
-
谢谢,我明白了。
标签: python automatic-ref-counting python-imaging-library geometry