use unsigned shorts to support > 32k images