Fixed definition of lower image coordinate bounds to avoid segmentation violations in particular configurations.