Get Even More Visitors To Your Blog, Upgrade To A Business Listing >>

Circle Function - Computer Graphics CG Program

Statement: void circle (int x,int y,int radius);

Circle function is used to draw a circle with center (x, y) and the third parameter is the radius of the circle. The following code draws a circle.

In the following program (100, 100), the coordinates of the circle center and 50 is the radius of the circle.

#include
#include

main() {
   int gd = DETECT, gm;

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

   circle(100, 100, 50);

   getch();

   closegraph();

   return 0;
}


This post first appeared on Ask For Program, please read the originial post: here

Share the post

Circle Function - Computer Graphics CG Program

×

Subscribe to Ask For Program

Get updates delivered right to your inbox!

Thank you for your subscription

×