fix bug in erosion of 16 bit images with some linear strels