Added thumbnail generating (requires PIL)