This creates a grid and sets the RGB of each clip based on the distance of the wave's center to the mc. I have it pretty well commented in the FLA. The center is dynamically positioned on a 4 petaled polar rose.<br /><br />All of the color manipulation is dynamic <--<br /><br />Alright, here is a quick explanation:<br />1. Inside of each of those orb things there is a simple circle movie clip<br />2. The setRGB method needs to have hexadecimal colors, but they are rather clumsy to work with so I made a RGB 0-255 class that you can convert back to hexadecimal by the function toHex(). <br />3 So, you have a variable for red that goes from 0-255, green that goes from 0-255, and blue that goes 0-255<br />4. Each one of these variables is set based on the distance of a point that is moving around a polar rose (see fla /math texts) relative to the circle movieclips.<br />5. When these R G and B values are set they are also made to have the colors wave, and as you probably know the sin function works great for that, for the equation for a sine curve is Amplitude*Math.sin(Math.PI/180*Wavelength+Phase). Yes, I know people that the wavelength is a bit off, but I am trying to keep it simple. So in this case the amplitude is 255 so the colors can be 0-255, the wavelength is set based on the distance from the origin thing and the phase is adjusted differently for R G and B so that it is not monochrome (all the values being the same) . <br /><br />Thats about it :D I will probably add mouse interactivity soon.
freeskier89 (34)
Color Wave
This creates a grid and sets the RGB of each clip based on the distance of the wave's center to the mc. I have it pretty well commented in the FLA. The center is dynamically positioned on a 4 petaled polar rose.<br /><br />All of the color manipulation is dynamic <--<br /><br />Alright, here is a quick explanation:<br />1. Inside of each of those orb things there is a simple circle movie...
< less
more >
1291 downloads, 14609 views
You need to login to post a comment .
very nice