0% found this document useful (0 votes)
13 views11 pages

CGR Microproject

Uploaded by

akshayarsul06
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views11 pages

CGR Microproject

Uploaded by

akshayarsul06
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 11

ADITYA POLYTECHNIC, BEED

Micro Project On
“ Design colourful circles ”
Submitted By
Gaikwad Vishal Shivaji
Under The Guidance Of
Prof. shaikh k.f.
For The Subject
Computer Graphics
Department Of
Computer Science And Engineering
2023-24

1
CERTIFICATE

This is to certify that Gaikwad Vishal Shivaji from Aditya


Polytechnic Beed Institute Having Enrollment no. 2209590325 has
completed Micro Project of second year computer graphics subject
having Title colourful circles during academic year 2023-2024 The
project completed by Student under the guidance of the faculty Prof.

Shaikh k.f.

Name and signature of guide ……………………................................

2
Acknowledgement
A project work of a great significance is not possible without
the help of several people, directly or indirectly. First and
foremost we have immense happiness in expressing our
sincere thanks to our guide, Ms. Shaikh k.f. for his valuable
suggestion, co-operating and continuous guidance.

We feel a deep sense of gratitude to Mr. Shaikh S.I., Head of


computer science department for his continuous
encouragement and for developing a keen interest in the field
of computer science. it's our pleasure to thank Mr.Khadke R.N
principal of Aditya Polytechnic. Beed, who is always a
constant source of inspiration.

We are very much thankful to all our faculty members whose


presence always inspires us to do better. Our happiness
culminates, when we recall the co-operation extended our
friends during the completion of this project.

Project Team:- Gaikwad Vishal Shivaji

3
Index

Sr.no chapters Page.no

1. Introduction 05

2. Requirement 06

3. Snapshots 07
4. Code 08

5. Output of code 09
6. Reference 10
7. Conclusion 11

4
1. Introduction
Here is a C graphics program to draw colourful
circles on screen using graphics.h header file. In this
program, we will draw multiple circles on screen
with different sizes .
Initgraph:- initializes the graphics system by
loading the passed graphics driver then changing the
system into graphics mode.
Getmaxx:- returns the maximum X coordinate in
current graphics mode and driver.
Getmaxy: returns the maximum Y coordinate in
current graphics mode and driver.
“C:\\Turboc3\\BGI”:- This is the directory path where
BGI files are stored, This directory only work with Turbo C
(DOS) Editor.
delay();- delay function stored under dos.h for
holding the function for some time.
Getch();-to hold the output screen for some time
until the user passes a key from the keyboard to exit
the console screen.

5
2.Requirements
 Hardware:
Processor : intel i3.

Ram : 4gb/8gb

Storage : 256gb

 Software:

Operating system : windows 7/10

Software Tool : turbo c\c++

6
3.Snapshots

7
4.Code
1. #include<stdio.h>
2. #include<conio.h>
3. #include"graphics.h"
4. #include"stdlib.h"
5. void main()
6. {
7. intgd=DETECT,gm,i=0,x,xx,y,yy,r;
8. //Initializes the graphics system
9. initgraph(&gd,&gm,"c:\\tc\\bgi");
10. x=getmaxx();
11. y=getmaxy();
12. while(!kbhit())
13. {
14. i++;
15. // setfillstyle(random(i),random(30));
16.
17. circle(xx=random(x),yy=random(y),random(3
0));
18. setfillstyle(random(i),random(30));
19. floodfill(xx,yy,getmaxcolor());
20. delay(200);
21. }
22. getch();
23. }

8
5. output of code

9
6. Reference
The reference from internet, following
websites,links have been used in the completion of
this project file:

 Websites:
https://www.javatpoint.com
https://www.softpedia.com
https://thesmolt.com

Following Books are used to have an idea about this


Project

 Computer graphics.

Various Articles used to implement this project.

10
7.Conclusion
In this project, we drawn the colourful circles with
different sizes and program is executed .

In this program we first initialize graphics mode, by


passing graphics driver(DETECT), default graphics
mode and specifies the directory path where
initgraph looks for graphics drivers (*.BGI). It is the
first step you need to do during graphics
programming. Setting graphics driver as DETECT,
means instructing the compiler to auto detect
graphics driver. Here we are using getmaxx and
getmaxy function to find the centre coordinate of the
screen and setcolor function to change he colour of
drawing.

11

You might also like