c graphics
Wednesday, 11 July 2012
Monday, 9 July 2012
toy
#include<stdio.h>
#include<graphics.h>
#include<conio.h>
void main()
{
int gd=DETECT,gm,i;
initgraph(&gd,&gm,"");
cleardevice();
setbkcolor(7);
circle(300,200,35);
circle(280,190,3);
circle(320,190,30;
line(300,235,300,450);
line(300,290,250,320);
line(300,290,350,320);
line(300,350,250,400);
line(300,350,350,400);
getch();
}
#include<graphics.h>
#include<conio.h>
void main()
{
int gd=DETECT,gm,i;
initgraph(&gd,&gm,"");
cleardevice();
setbkcolor(7);
circle(300,200,35);
circle(280,190,3);
circle(320,190,30;
line(300,235,300,450);
line(300,290,250,320);
line(300,290,350,320);
line(300,350,250,400);
line(300,350,350,400);
getch();
}
C graphics program for olympic symbol
C Graphics Program To Make Different Shapes
#include<graphics.h>
#include<conio.h>
void main()
{
int gd=DETECT,gm,points[]={320,150,440,340,230,340,320,150};
initgraph(&gd,&gm,"");
setbk color(3);
setcolor(6);
bar3d(380,380,430,430,20,1);
setcolor(2);
bar(165,165,230,230);
setcolor(9);
circle(480,180,350;
floodfill(480,180,9);
fillpoly(4,points);
rectangle(100,110,155,150);
getch();
closegraph();
}
#include<conio.h>
void main()
{
int gd=DETECT,gm,points[]={320,150,440,340,230,340,320,150};
initgraph(&gd,&gm,"");
setbk color(3);
setcolor(6);
bar3d(380,380,430,430,20,1);
setcolor(2);
bar(165,165,230,230);
setcolor(9);
circle(480,180,350;
floodfill(480,180,9);
fillpoly(4,points);
rectangle(100,110,155,150);
getch();
closegraph();
}
Subscribe to:
Posts (Atom)