Ads

CIRCLE ANIMATION IN C PROGRAMMING | C++ PROGRAM TO CREATE CIRCLE ANIMATION | HOW TO CREATE CIRCLE ANKMATION IN C++ | C LANGUAGE | C++ PROJECT

 //.......... WELCOME ALL OF YOU ON ROHIT TECH STUDY CHANNEL ...............

//.............. C++ PROGRAM TO CREATE CIRCLE ANIMATION .................


#include<stdio.h>

#include<conio.h>

#include<dos.h>

#include<graphics.h>

void main()

{

int gd=DETECT, gm, x, y, angle=0;

struct arccoordstype a, b;


initgraph(&gd, &gm, "C:\\TC\\BGI");


//_____TEXT

 setcolor(15);

 settextstyle(3,HORIZ_DIR,2);

 outtextxy(160,445,"CREATED BY :- ROHIT TECH STUDY");


while(angle<=360)

{


//1th circle animation

setcolor(BLACK);

arc(getmaxy()/2,getmaxx()/2,angle,angle+2,190);


getarccoords(&a);

setcolor(14);

circle(a.ystart,a.xstart,20);


//2nd circle animation

setcolor(BLACK);

arc(getmaxx()/2,getmaxy()/2,angle,angle+2,150);


getarccoords(&a);

setcolor(12);

circle(a.xstart,a.ystart,25);


//3rd circle animation

setcolor(BLACK);

arc(getmaxy()/2,getmaxx()/2,angle,angle+2,110);


getarccoords(&a);

setcolor(13);

circle(a.ystart,a.xstart,25);


//4th circle animation

setcolor(BLACK);

arc(getmaxx()/2,getmaxy()/2,angle,angle+2,70);


getarccoords(&a);

setcolor(10);

circle(a.xstart,a.ystart,15);


//5th circle animation

setcolor(BLACK);

arc(getmaxy()/2,getmaxx()/2,angle,angle+2,40);


getarccoords(&a);

setcolor(4);

circle(a.ystart,a.xstart,15);


//6th circle animation

setcolor(BLACK);

arc(getmaxx()/2,getmaxy()/2,angle,angle+2,10);


getarccoords(&a);

setcolor(15);

circle(a.xstart,a.ystart,15);


angle = angle+5;

delay(50);

}


getch();

closegraph();

}


//............... I HOPE YOU LIKE THIS PROGRAMMING ...................


//............ LIKE .......... SHARE .......... SUBSCRIBE ..............


Post a Comment

0 Comments