All posts from day posts/2007/08/18.

Ethan Ethan

After implementing some of the stuff for human mode this afternoon, I implemented the memory-saving optimization I had been thinking about for a couple of days. Basically, previously I had been reusing image files to create animations; now I use each image file once, but read a supplementary "index" file to find out what images are used in which order. This makes stretching parts of an animation a lot easier, and should cut a significant amount of RAM usage from healbeam2. But it doesn't. I'm not sure why, but adding one room takes something like 8% of my machine's RAM, and almost all of it is in this one set of 11 images. The images themselves are about 3 MB uncompressed, which should be something like 1% of my machine's RAM. Very perplexing..


[Edit: found it! The Image shape calls Image.flip_strip, which constructs new surfaces wastefully if they aren't needed.]

Posted Sat 18 Aug 2007 11:35:30 PM PDT Tags:
Last edited Sat 29 Sep 2007 11:10:27 PM PDT