bjordal i am glad you asked.
Processing's core power I believe is it's pixel array manipulation techniques. You can do stuff with the pixel array in Processing so easily that takes so much work with other programming languages it's scary. What I basically do is use pixels to store universal layers of data. Each pixel has four possible values (r-Red g-Green b-Blue a-Alpha) with this basic setup I create sketches. I can then take an image and move it sketch to sketch seamlessly.
Processing has its .pde extension but I am a fan of real-time pixel manipulation. I hate having to close a sketch and edit code and hitting the play button and copying multiple tabs of sketches and then installing libraries to run sketches I find online.
I just want one file that can contain audio, video, motion , code and whatever else I want to store. I use this for all of my sketches. All processing code is basically a text file fill with a series of letters from the 26-letter alphabet punctuated by
curly and square brackets { } []
periods and semi-colons . ;
and capitalization where applicable - void keyPressed()
What I am using this one for is to read any image that has a spectrum colours in it (for example the colour wheel in Microsoft Excel) and then use it generate a 3d image without knowing the co-ordinates before hand.
Coincedently when you guys mentioned that the transitions are not smooth; there is a reason for that. We can only store 2d data one layer at a time.
Example
http://en.wikipedia.org/wiki/RGB_color_model
http://upload.wikimedia.org/wikipedia/commons/thumb/8/8d/RGBR.png/256px-RGBR.png
- (255, 255, 255) is white
- (255, 0, 0) is red
- (0, 255, 0) is green
- (0, 0, 255) is blue
- (255, 255, 0) is yellow
- (0, 255, 255) is cyan
- (255, 0, 255) is magenta
|
yellow (255,255,0) |
green (0,255,0) |
cyan (0,255,255) |
red (255,0,0) |
 |
blue (0,0,255) |
|
red (255,0,0) |
magenta (255,0,255) |
Once you imagine colour values as co-ordinates you realize how easily it can be used to generate a 3d image from pre-existing colours we see everyday but take them for granted.
For example the above image results in a the following 3d image
As you can see from the image above. You can see the image as the background , I just made changed the empty space to black which is zero and not white which is 255.
Then you just call beginShape(QUADS) and then use the pixels to control the vertex(x,y,z) the x-axis is red . the y-axis is green and the z-axis is blue
I will post the images from your algorithm bjordal.
Anyone desiring to see the code, you can email me at
owuanz@gmail.com or post your email address here.