Browse code

paster.pike: fix bug with images without alpha (the generated alpha was inverted, so the resulting image was transparent)

Dario Rodriguez authored on 28/10/2020 23:59:16
Showing 1 changed files
... ...
@@ -68,7 +68,7 @@ write("r:"+r+" g:"+g+" b:"+b+" a:"+a+"\n");
68 68
 				alpha=alpha->scale(xsize,ysize);
69 69
 		}
70 70
 		if(intp(alpha))
71
-			alpha=Image.Image(xsize,ysize)->clear(0,0,0);
71
+			alpha=Image.Image(xsize,ysize,255,255,255);
72 72
 		l=Image.Layer(image,alpha,"normal");
73 73
 		l->set_offset(xoff,yoff);
74 74
 		layers+=({l});