This is a question about Processing.org.
I am fading out previously drawn objects by drawing a semi-transparent white rectangle over the view for every frame.
However, it appears that they never fade to completely white. The fading has a fixed point at some noticeably non-white shade of grey. Same thing happens when trying to fade to black.
Is this a standard feature of how alpha-blending works in processing? Is there a relatively easy way around it, to achieve a completely white background (given enough steps)?
I imagined the resulting colour would be a linear combination of the colours that are blended, which means the limit should be white. Perhaps the non-white fixed point is an artefact of rounding?
Sample code illustrating the issue:
void setup() {
size(300,300);
background(0);
noStroke();
frameRate(15);
}
void draw() {
fill(255,10);
rect(0,0,width,height);
fill(255);
rect(0,0,50,50); // for comparison to white
}
edit: added java tag in hope of more attention