© 1999-2048 dssz.net 粤ICP备11031372号
[其它] python使用PIL模块获取图片像素点的方法
说明:如下所示: from PIL import Image ########获取图片指定像素点的像素 def getPngPix(pngPath = "aa.png",pixelX = 1,pixelY = 1): img_src = Image.open(pngPath) img_src = img_src.convert('RGBA') str_strlist = img_src.load() data = str_strlist[pixelX,pixelY]<weixin_38704786> 上传 | 大小:31kb