changed rowPolygon Array to 1D