Today we will study how to make a car in C++ using Computer Graphics.
#include<iostream.h>
#include <conio.h>
#include<stdlib.h>
#include<graphics.h>
void main()

{
int midx=150, midy=150, stangle=0, endangle=180, radius=40;
int midx1=300, midy1=150, stangle1=0, endangle1=180, radius1=40;
int d=DETECT,g;
initgraph(&d,&g,"c://tc//bgi");
for(int x=1,y=10; x<=500 ;x++)
{
arc(midx, midy, stangle, endangle, radius);
line(357, 150, 342, 150);
line(357, 104, 357, 150);
line(340,100,357 , 104);
line(280, 75, 340,100);
line(140,75,280 ,75 );
line(110, 100, 140,75 );
line(85, 100, 110, 100);
line(85, 150, 85, 100);
line(110,150, 85, 150);
line(190, 150, 260, 150);
arc(midx1, midy1, stangle1, endangle1, radius1);
circle(300, 150,33);
circle(150, 150,33);
circle(150, 150,7);
circle(300,150,7);}
getch();
closegraph();
getch();
}
Posted by Unknown On Friday, April 26, 2013 3 comments

3 comments:

  1. I am hoping the same best effort from you in the future as well. In fact your creative writing skills has inspired me. https://www.eliaandponto.com/michigan-car-accident-lawyer/michigan-hit-and-run-accident-lawyer/

    ReplyDelete
  2. I’ve read some good stuff here. Definitely worth bookmarking for revisiting. I surprise how much effort you put to create such a great informative website. Wedding Toronto Limousine

    ReplyDelete

  • RSS
  • Delicious
  • Digg
  • Facebook
  • Twitter
  • Linkedin
  • Youtube

Like us

    as

    Contact Form

    Name

    Email *

    Message *