Professional Documents
Culture Documents
Academic year
2023-24
Flying Balloons
Certificate
This is to certify that Mr. Purva Jagtap , Pushkar shinde , Devesh Chandiramani
VES POLYTECHNIC (Code: 0004) has completed the Micro Project satisfactorily in Subject –
Computer Graphics (22318) for the academic year 2023-2024 as prescribed in the curriculum.
4
1 Project Proposal
5
2 Action plan
6
3 Resource required
7
4 Introduction
8
5 Actual Procedure
11
6 Output
12
7 Skill developed
15
8 Evaluation sheet
Annexure – I
Micro-Project Proposal
Flying Balloons
Micro-Project Report
Flying Balloons
1.0 Rationale
In computer graphics, we use graphics header file which provides direct functions to draw
different co-ordinate shapes (like circle, rectangle, triangle, line etc.), Using these functions
only we can draw different object like cycle, mountains, sun etc. In this program, we will draw
a Flying balloon using lines and circles and using a for loop we will make the Balloons flying.
The `draw Balloon` function is responsible for drawing a single balloon. It uses graphics functions to
create a red circle for the balloon body and a brown line for the rope. This function encapsulates the
visual representation of a balloon.
In the `main` function, the graphics environment is initialized, and the background color is set to blue.
It creates an array of `Balloon` structures to manage multiple balloons. These balloons are initially
positioned at the bottom of the screen, forming a visually appealing arrangement.
The main loop of the program allows for user interaction. It checks for keyboard input, specifically
the left and right arrow keys for moving the balloons horizontally. Additionally, it allows the user to
exit the program by pressing 'e' or 'E'.
Within the animation loop, the screen is cleared on each iteration, and all balloons are drawn and
moved upwards, creating the illusion of them floating. If a balloon goes off the top of the screen, it is
repositioned at the bottom to maintain a continuous animation.
A slight delay is introduced to control the animation speed, giving a pleasant visual effect.
In summary, this code combines the power of C programming and Turbo C's graphics library to create
an entertaining animation of balloons. It's a great example of how code can be used to produce visually
engaging and interactive content. The code is well-structured, with clear comments and a logical flow,
making it easy to understand and modify.
Algorithm
Step 1 . Start
Step 2. Include the necessary header files for graphics and input handling.
Step 4. Create a structure `struct Balloon` with `x` and `y` coordinates to represent a
balloon.
Step 5. Define a function `draw Balloon` that draws a balloon and its rope on the screen.
Step7.stop
Flowchart:
Code :
#include <stdio.h>
#include <conio.h>
#include <dos.h>
#include <stdlib.h>
#include <graphics.h>
#define MAX_BALLOONS 5
struct Balloon {
int x, y;
};
int main() {
int gd = DETECT, gm;
initgraph(&gd, &gm, "C:\\Turboc3\\BGI");
int flag=1,i;
// Set the background color (e.g., blue)
setbkcolor(BLUE);
cleardevice();
// Draw all balloons
for (int i = 0; i < numBalloons; i++)
{
drawBalloon(balloons[i].x, balloons[i].y);
balloons[i].y--;
closegraph();
return 0;
}
2 Windows 11
1. Designing: Designing of micro project with minimum required resources and at low cost.
6. Technical writing: Preparing a report of the proposed plan and final report.
Sr.
Characteristic to be Poor Average Good Excellent
No (Marks1-3 )
Sub Total
assessed (Marks 4-5 ) (Marks 6-8) ( Marks9-10)
.
(A) Process and Product Assessment (Convert Above Total marks out of 6 Marks)
1 Relevance to the course
Literature Review /
2
information collection
Completion of the Target as
3
per project proposal
Analysis of Data and
4
representation
5 Quality of Prototype/Model
6 Report Preparation
Individual Presentation / Viva (Convert above total marks out of 4 marks)
7 Presentation
8 Viva
Process and Product Assessment Individual Presentation / Viva Total Marks
Roll No. (6 Marks) (4 Marks) 10
31
32
33