PROGRAM TO DEMOSTARTE SETFILLSTYLE AND FLOODFILL

//PROGRAM TO DEMOSTARTE SETFILLSTYLE AND FLOODFILL

#include<iostream.h>

#include<conio.h>

#include<graphics.h>

#include<dos.h>

#include<stdio.h>

void main()

{

intgd=DETECT,gm,i=0;

initgraph(&gd,&gm,””);

while(!kbhit())

{

setfillstyle(1,WHITE);

floodfill(11,11,GREEN);

setcolor(BLACK);

if(i==12) i=0;

setfillstyle(i,RED);

rectangle(10,10,200,200);

floodfill(11,11,BLACK);

gotoxy(1,15);

cout<<“This is FillStyle No. = “<<i;

delay(1000);

i++;

}

}

Leave a Reply

Your email address will not be published. Required fields are marked *