Prevent overflows during mpeg->jpeg yuv.