…whirling silently in space…

My idea for the lighting effect was to use the sine of the angle of each criss-crossing line as the basis for the line’s saturation and brightness (using the HSB colour mode rather than RGB). That way, I figured, the lines would be brightest when sloping at 45 degrees, and darkest after they had turned a further 90 degrees. That should suggest a constant light source emitting parallel rays onto the rotating blobs.

It didn’t work, however, because the lines never changed their values, and it took me a while to work out why. By using pushMatrix(), translate(), rotate() and popMatrix() to handle all of the complex calculations, the angles remained constant because the drawing window was translated and rotated, not the lines themselves. I need to go back to my original intention to recalculate new values for the co-ordinates of each end of every line in every frame.

This may take a while…

Tags: ,

Wednesday, April 29th, 2009 coding

Leave a Reply