【发布时间】:2013-07-20 17:55:53
【问题描述】:
我正在尝试将两张图片交织在一起。
图一图二这个
def interWeave(pic, picture):
w=getWidth(pic)
h=getHeight(pic)
newPic=makeEmptyPicture(w,h)
for x in range (0,w):
for y in range (0,h):
p=getPixel(pic,x,y)
p2=getPixel(picture,x,y)
newPxl=getPixel(newPic,x,y)
if (x>=0 and x<20) or (x>=40 and x<60)or (x>=80 and x<=100):
color = getColor(p)
else:
color=getColor(p2)
setColor(newPxl, color)
return (newPic)
但我明白了:
有人知道我做错了什么吗?
【问题讨论】:
标签: python jython crop image getpixel