03-05-2015 04:27 AM - edited 03-05-2015 04:28 AM
hi desalando,
as an alternative to eroding pixels, you might convolute your 2-color input with an 2d gauss-kernel and then calculate the global maximum in each row or column.
03-05-2015 08:41 AM
Yes, I knew you would get the same results from odd and even widths. I was going to mention that, but I forgot. When you divide by two and get an integer, it is kind of implied. You can't get half a pixel.
I suppose one solution would be doubling the resolution of your image, then running it. The results would be correct for the original image, I believe. It would be an interesting experiment.
Bruce