摘要:
PIL 提供了丰富的功能模块:Image,ImageDraw,ImageEnhance,ImageFile 等等。最常用到的模块是 Image, ImageDraw,ImageEnhance 这三个模块。1、Image模块 最基本的模块,每个Image对象对应了一幅图像,基本的功能如下: 1 from PIL import Image2 img = Image.open('pic.jpg')#打开一幅图像3 new_img = img.resize((128.128),Image.BILINEAR)#调整图像大小4 new_img.save('pic_r.jp' 阅读全文
posted @ 2012-04-04 01:23
Goodpy
阅读(4699)
评论(0)
推荐(0)

浙公网安备 33010602011771号