Replying to:MZ952
This only supplements color with the blue color channel. Could it be better to—say—take the average of R,G,B and use that value instead?
DEF GRAYSCREEN X0,Y1,X1,Y1 VAR X,Y,R,G,B FOR Y = Y0 TO Y1 FOR X = X0 TO X1 RGBREAD GSPOIT(X,Y) OUT R,G,B GPSET X,Y,GRAY((R+G+B)/3) NEXT NEXT END DEF GRAY(V%) RETURN RGB(V%,V%,V%) END
I thought this as well, but Randomous pointed out that B is in fact reassigned to the average of the three channels before writing.
Choosing a different name would have been better though, and it still doesn't take into account the alpha bit.