From what I can tell, it almost looks as if the Stonehenge post and Image::Seek are using the same algorithm. I'm looking specifically at haar.cpp from Image::Seek. Anyway, Image::Seek is a really good starting point. I think what I am going to do is make some minor modifications to the source to fit my needs. I will post my results once finished.