Hey guys i’m a newbe to the whole vvvv interface and programming… but till what i have seen and been able to achieve i’m very impressed, just love the program. just to give you a bit of background im developing a FTIR based multiuser multitouch interface for my university project. I’ve been playing around with a lot of things however the wave simulation caught my eye, ive got it to work with my blob tracker and now it can support multiple inputs, and what not.
But on the my problem, well first of all im not sure if im posting in the correct area, if i’m not im sorry, maybe an admin can move the post, to a caorrect area. Anywho my problem is that im using gregsn’s wave simulation, i want to know how can i change the colour of waves, to say green or blue or red…
And is there a way i can cycle the colours slowly with smooth transitions say every 2min or something along the lines.
wave02.zip (22.3 kB)
the trick is to use the output of the waveshader patch (the black&white texture) as a height map for just another rendering step.
so in that final rendering step you would not think about how the waves are produced but only how they can be embedded into a 3d scene. normally you would want to use light and material properties to influence the rendering of the 3d water surface.
this task is very similar to rendering a simple xfile with a phong shader. the only difference is that you don’t render a precomputed xfile with that phong shading technique, but that you want to render a flat grid (Grid EX9) and use the height map to transform that flat thing into a water surface.
sorrily i have no didactic outof the box thing for you right now.
at the end you need to write a shader which does both transforming the heightmap into a normalmap (or just a normal vector in the pixelshader) and feed that into the phong lighning pipeline.
if you only want to colorize the b&w heightmap then maybe a sort of color transform could help. (color vector * color matrix)
i hope this helped a little bit.