Another correction to farmland lines
This commit is contained in:
parent
fbb7112388
commit
3402d2f2a8
@ -269,7 +269,7 @@ class mstr_maskgen:
|
|||||||
lines = Image.new("RGBA", (2048,2048))
|
lines = Image.new("RGBA", (2048,2048))
|
||||||
mask_pix = mask_img.load()
|
mask_pix = mask_img.load()
|
||||||
pts = []
|
pts = []
|
||||||
for l in range(96, 201):
|
for l in range(21,51):
|
||||||
p = ( randrange(0,2048), randrange(0,2048) )
|
p = ( randrange(0,2048), randrange(0,2048) )
|
||||||
pts.append(p)
|
pts.append(p)
|
||||||
imgl = ImageDraw.Draw(lines)
|
imgl = ImageDraw.Draw(lines)
|
||||||
@ -278,8 +278,9 @@ class mstr_maskgen:
|
|||||||
linepix = lines.load()
|
linepix = lines.load()
|
||||||
for y in range(0, 2048):
|
for y in range(0, 2048):
|
||||||
for x in range(0, 2048):
|
for x in range(0, 2048):
|
||||||
|
mp = mask_pix[x,y]
|
||||||
lp = linepix[x,y]
|
lp = linepix[x,y]
|
||||||
if lp[3] > 0:
|
if lp[3] > 0 and mp[3] > 0:
|
||||||
c = (0,0,0,255-lp[3])
|
c = (0,0,0,255-lp[3])
|
||||||
mask_pix[x,y] = c
|
mask_pix[x,y] = c
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user