For some months there have been a hot topic in
Papervision3D's mailing list which is the special materials for the engine.
In the early days
Ralph did an example with
environment mapping but for some reason, the guy didn't want to share the code at that moment and they have been working on all this for a long time now, showing some examples some months afterwards and then seems like there are no more news on the front. I just hope that we won't do 1 year of papervision3d since the release and we still have only normal texture mapping. C'mon Ralph!
Then, these days the materials topic started again thanks to
Fabrice (a.k.a the browser killer). Releasing experiments in
Ralph's style, testing similar things. However, with
Ralph experiments it was easy to see that the calculations were real as the objects were complex. But
Fabrice's examples were using spheres, planes, and simple objects, which made me think that he was cheating (He isn't).
So, then is when I had the idea of speding 1hour and doing a couple of examples of
fake materials (so, cheating) to achieve similar results than what Fabrice was showing (although without killing any browsers ;D).
And these are the results...
(
click on the images to see them moving)
Wood
Metal
Weird
Weird 2

They are fake, they only work in specific 3dobjects (basicaly simple mapped 3dobjects). But well, I'm sure you'll find a good place to use it :) The really cool thing of this technique is that is really fast, it runs at
20FPS+ in my iBook G4, and I'm sure it can be optimised.
What I'm doing is very simple. You have
2 bitmaps, one that you use as a
diffuse map and as
bump map, and then another one as
"environment map"... wait a second, I think it will be easier if you take a look at the .fla instead of me trying to explain step by step what's going on.
Here you have the source code.Enjoy!
#permalink
Share:Digg! ~
del.icio.us ~
Stumble ~
Furl ~
Reddit