build small jpegs first