Sunday 8 February 2009

Metaballs

Its been a while since i'v posted, been busy with work etc. Anyway, after playing GoW2 and the Kilzone 2 demo (which has also got me thinking about developing another defered shading engine at work, I don think it would ever get used but it would be a cool feature to add to our engine) I was wondering how the blood created. I did some digging around and I found these things called metaballs (or isosurfaces). Theres a great introduction article on GameDev, from it I as able to implement a simple metaball system in render monkey.
Using the equations in the article, you basically iterate through each metaball in the pixel shader and return the summation of affect each metalball has on the pixel. Its pretty cool stuff and not to hard to implement:

No comments: