Bound the maximum size of photo