mapContour() improvements