Bitmap/Midpoint circle algorithm: Difference between revisions

Tweak
(→‎{{header|REXX}}: removed the need for end-of-earth plot field, simplified the program, added comments and whitespace, changed indentations.)
(Tweak)
Line 1,563:
data.clear(); sz.pump(data,T(Void,rgb.toBigEndian(3)));
}
fcn __sGet(x,y) { data.toBigEndian(3*y*w*3 + x,3); } //ppm[x,y]
fcn __sSet(rbg,x,y){ data[3*y*w*3 + x*3,3]=rbg.toBigEndian(3); } //ppm[x,y]=rgb
fcn write(out){
out.write("P6\n#rosettacode PPM\n%d %d\n255\n".fmt(w,h));
Anonymous user