A Tilestache config file has a "png options" object that passes its config straight through to the Python Imaging Library (PIL). Setting
optimize: true does some kind of optimization as the file is being written by PIL. I've found that using tools like optipng or pngout can yield further optimization.
Is there some hook I can use, or a way to tell Tilestache to run optipng and pngout on the tiles once they're cached?
I found a tool called picopt that does this sort of thing; I could run it on the cache folder, but I'd like to know how I can have Tilestache do this automatically.
Or, if I'm barking up the wrong tree, what's the best practice for optimizing map tiles?