HI I AM TANZIM NOW I STUDYING IN PUNDRA UNIVERSITY,BOGRA,BANGLADESH ***WELCOME MY WEBSITE**.

Graphics in c (Draw bangle front)



  




 CODE FOR TC:

///BANGLA FORNT WRITE IN GRAPHICS\\\\\


#include <stdio.h>
#include <graphics.h>
#include <conio.h>
#include<dos.h>

int main() {
    int gd = DETECT, gm;
     /* initialize graphic mode */
    initgraph(&gd, &gm, "C:\\TC\\BGI");
    /////////////////////////////////////////
    setbkcolor(14);
    setcolor(RED);
    settextstyle(2,0,5);
    outtextxy(260,15,"MD.TANZIM HOSSEN");
    outtextxy(175,30,"PUNDRA UNIVERSITY OF SCINCE & TECHONOLOGY");
    outtextxy(260,45,"CSE 3rd BATCH");
    outtextxy(245,60,"ID No:00315306009");
    /////////////////////////////////
    setcolor(GREEN);
    delay(500);
    rectangle(0,100,600,400);
    ////////////////////////////
   delay(800);
    setcolor(BLUE);
    line(10,200,600,200);
    delay(1000);
   ellipse(93,214,0,360,7,7);
    ellipse(50,215,180,360,50,130);
    ellipse(115,270,90,270,0,70);
    //////////////////////////////
    delay(1100);
    ellipse(168,340,0,180,35,50);
   ellipse(140,334,0,360,8,8);
    line(202,200,202,340);
    //////////////////////////////////
   delay(1200);
    line(290,270,290,200);
    line(290,270,340,270);
    ellipse(290,270,180,360,50,50);
    line(290,240,380,270);
    line(340,350,378,270);
    line(400,200,400,340);
    ellipse(320,200,0,180,80,60);
    ///////////////////////////////////
   delay(1300);
   ellipse(450,230,90,270,25,30);
   ellipse(450,281,250,90,25,20);
   ellipse(440,287,0,360,15,15);
   line(450,300,530,330);
   line(530,200,530,330);
    /////////////////////////////

    getch();
    closegraph();
    return 0;
}

                                          DESCRIPTION

Bangla  front  draw  in graphics

 Uses c language
  Draw the bangla word  তানজীম
Uses 4 header file in this program
#include <stdio.h> use because this program write c language.
#include<graphics.h> use because this program write in graphics mode.
#include<conio.h> use for compiler terbo c.
#include <dos.h> use for delay() function.
………………………………………………………..
This part uses for initialize graphic mode 

   int gd = DETECT, gm;
     /* initialize graphic mode */
    initgraph(&gd, &gm, "C:\\TC\\BGI");

……………………………………………………………….

    setbkcolor(14);
    setcolor(RED);
    settextstyle(2,0,5);
    outtextxy(260,15,"MD.TANZIM HOSSEN");
    outtextxy(175,30,"PUNDRA UNIVERSITY OF SCINCE & TECHONOLOGY");
    outtextxy(260,45,"CSE 3rd BATCH");
    outtextxy(245,60,"ID No:00315306009");

This part uses for Display Personal information. And uses outtextxy(); function.
outtextxy();
            actually this function uses for Display current position any string.
Declaration:
      Outtextxy(int x, int y, “string”);
Delay:
 Void delay(unsigned milliseconds);
………………………………………………………….

    setcolor(GREEN);
    delay(500);
    rectangle(0,100,600,400);

Rectangle();
This part uses for draw a rectangle
Declaration:
         rectangle(int left,int top,int right, int bottom);
Setcolor();
         Setcolor sets the current drawing color to color, which can range from 0 to getmaxcolor.
............................................................................

  delay(800);
    setcolor(BLUE);
    line(10,200,600,200);
    delay(1000);
   ellipse(93,214,0,360,7,7);
    ellipse(50,215,180,360,50,130);
    ellipse(115,270,90,270,0,70);

 
This part uses for draw bangle word তা
Line();
Line draws a line between two specified point.
Declaration:
   Void far line(int x1,int y1,int x2,int y2);
Circle();
       Draw a circle
Declaration:
    Void far circle(intx, int y, int radius);
Ellipse();
         Ellipse draws an ellipse arc
Declaration:
         Void far ellipse(int x, int y, int stangle, int endangle, int xradius, int yradius);
………………………………………………………………………………………………………….



    delay(1100);
    ellipse(168,340,0,180,35,50);
   ellipse(140,334,0,360,8,8);
    line(202,200,202,340);




This part uses for draws a bangle word is
……………………………………………………


delay(1200);
    line(290,270,290,200);
    line(290,270,340,270);
    ellipse(290,270,180,360,50,50);
    line(290,240,380,270);
    line(340,350,378,270);
    line(400,200,400,340);
    ellipse(320,200,0,180,80,60);


This part uses for draws a bangle word is জী
………………………………………………….


delay(1300);
   ellipse(450,230,90,270,25,30);
   ellipse(450,281,250,90,25,20);
   ellipse(440,287,0,360,15,15);
   line(450,300,530,330);
   line(530,200,530,330);

This part uses for draws a bangle word is
……………………………………………………


   getch();
    closegraph();
    return 0;

Getch();
    Getch gets a character from console but does not echo to the screen
Closegraph();
    Shuts down the graphics system 


THANK YOU

No comments:

Post a Comment