Floodfill function in C++

Floodfill function when executed fills an enclosed area with the colour and pattern to be inserted given  by the user. The pattern to be filled is given through setfillstyle() function.


This function requires three arguments. The first two are any coordinates inside the bounded region and the third one is the border colour. The general syntax of floofill() function is:

Floodfill(int x,int y,int border);

In the above syntax, x and y are any points inside the region and the border is the number representing the particular colour to be filled.




 class draw



                 void sketch()










    int main()



           int gd=DETECT,gm;

           draw c;






         return 0;



Floodfill function in c++