How to fill color correctly in closed curve using floodfill

use fillPoly or fillConvexPoly instead

related: