I used the Verlet integration and relaxation method described by Thomas Jakobsen in "Advanced Character Physics" [1] coupled with the animation techniques suggested by Chang, Jin, and Yu in [2] to make a fast hair simulation. My resulting video [3] was captured in real-time. The program can actually be sped up significantly by placing bounding boxes around individual quads, vertices, and segments; however, I ran into bugs when I tried to do this, so I left that optimization out for now. The results are interesting because they indicate that in video games, hair can be animated in real-time with relative ease. The source code has been placed in the public domain.
(Video) (Writeup) (Source Code)
Friday, June 16, 2006
Saturday, June 10, 2006
Automatic Python imports with autoimp
I got sick of writing "
(Module Website)
import X
" in Python. So, I created the public domain module autoimp
, which imports all modules automatically:>>> from autoimp import *Thus one no longer needs to write "
>>> os.stat('.')
>>> Image.open('test.bmp')
>>> pylab.plot([1,2],[3,4])
>>> scipy.linalg.eig([[1,2],[3,4]])
>>> ...
import X
". It would take too long to load every module when one writes "from autoimp import *
", so the imported modules are actually proxy objects which lazily load when they are first used.(Module Website)
Subscribe to:
Posts (Atom)