Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

Windmills Station Hub, Study Guides, Projects, Research of Computer Graphics

This is a simple Computer graphics project developed using Microsoft visual studio 2019. The code is written in C++.

Typology: Study Guides, Projects, Research

2020/2021
On special offer
30 Points
Discount

Limited-time offer


Uploaded on 01/12/2021

ashukk
ashukk 🇮🇳

5

(2)

2 documents

1 / 55

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Visvesvaraya Technological University
Belagavi, Karnataka, 590 014.
A Mini Project Report on
“WINDMILL”
Submitted in partial fulfillment of the requirements for the award of
Bachelor of Engineering in
Computer Science and Engineering
Semester VI
(17CSL68)
Academic Year 2020-21
Submitted By
USN
Mr. Ashutosh Kumar 2KE17CS007
Mr. Dheeraj Sangur 2KE17CS012
Mr. Kushal Bendigeri 2KE17CS019
Mr. Vishwanath Reddy 2KE17CS051
Under the Guidance of
Prof. Kiran B. Malagi
Department of Computer Science & Engineering
(Accredited by National Board of Accreditation [NBA] )
K. L. E. SOCIETY’S
K. L. E. INSTITUTE OF TECHNOLOGY,
Opp. Airport, Gokul, Hubballi-580 030
Phone: 0836-2232681 Website: www.kleit.ac.in
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
Discount

On special offer

Partial preview of the text

Download Windmills Station Hub and more Study Guides, Projects, Research Computer Graphics in PDF only on Docsity!

Visvesvaraya Technological University

Belagavi, Karnataka, 590 014. A Mini Project Report on

“WINDMILL”

Submitted in partial fulfillment of the requirements for the award of Bachelor of Engineering in

Computer Science and Engineering

Semester VI

(17CSL68) Academic Year 2020- Submitted By USN Mr. Ashutosh Kumar 2KE17CS Mr. Dheeraj Sangur 2KE17CS Mr. Kushal Bendigeri 2KE17CS Mr. Vishwanath Reddy 2KE17CS Under the Guidance of

Prof. Kiran B. Malagi

Department of Computer Science & Engineering

(Accredited by National Board of Accreditation [NBA] ) K. L. E. SOCIETY’S

K. L. E. INSTITUTE OF TECHNOLOGY,

Opp. Airport, Gokul, Hubballi-580 030

Phone: 0836-2232681 Website: www.kleit.ac.in

K. L. E. SOCIETY’S

K. L. E. INSTITUTE OF TECHNOLOGY,

Opp. Airport, Gokul, Hubballi-580 030

Phone: 0836-2232681 Website: www.kleit.ac.in

DEPARTMENTOF COMPUTER SCIENCE & ENGINEERING

(Accredited by National Board of Accreditation [NBA] )

CERTIFICATE

Certified that the mini project work entitled “WINDMILL” is a bonafide work carried out by Mr. Ashutosh Kumar, Mr. Dheeraj Sangur, Mr. Kushal Bendigiri, Mr. Vishwanath Reddy bearing USN number 2KE17CS007, 2KE17CS012, 2KE17CS019, 2KE17CS051 in partial fulfillment for the award of degree of Bachelor of Engineering in VI Semester, Computer Science and Engineering of Visvesvaraya Technological University , Belagavi, during the year 2020-21. It is certified that all corrections/suggestions indicated for internal assessment have been incorporated in the report deposited in the department library. The mini project report has been approved as it satisfies the academic requirements in respect of mini project work prescribed for the said degree. Signature of the Guide Signature of the HOD Signature of the Principal (Mr. Kiran B. Malagi) (Dr. Yerriswamy T.) (Dr. B. S. Anami)

K. L. E. SOCIETY’S

K. L. E. INSTITUTE OF TECHNOLOGY,

Opp. Airport, Gokul, Hubballi-580 030

DEPARTMENTOF COMPUTER SCIENCE & ENGINEERING

(Accredited by National Board of Accreditation [NBA] )

CERTIFICATE

This is to certify that the mini project report entitled “WINDMILL” has been successfully completed by Mr. Ashutosh Kumar, Mr. Dheeraj Sangur, Mr. Kushal Bendigiri, Mr. Vishwanath Reddy bearing USN number 2KE17CS007, 2KE17CS012, 2KE17CS019, 2KE17CS051 as a part of VI semester curriculum in Computer Science and Engineering of Visvesvaraya Technological University, Belgavi during the academic year 2020-21. It is certified that all the grammatical corrections/suggestions indicated have been incorporated in the report. Name: Seal & Signature:

ACKNOWLEDGEMENT

The mini project report on “WINDMILL” is the outcome of guidance, moral support and devotion bestowed on us throughout our work. For this we acknowledge and express our profound sense of gratitude and thanks to everybody who have been a source of inspiration during the project work. First and foremost we offer our sincere phrases of thanks with innate humility to our Principal Dr. B. S. Anami, who has been a constant source of support and encouragement. We would like to thank our Dean Academics Dr. S. G. Joshi, for his constant support and guidance. We feel deeply indebted to our H.O.D. Dr. Yerriswamy T. for the right help provided from the time of inception till date. We would take this opportunity to acknowledge our guide and coordinator Mr. Kiran B. Malagi who not only stood by us as a source of inspiration, but also dedicated his time and helped us in every aspect of our mini project work. Last but not the least, we would like to thank my parents, friends & well-wishers who have helped us in this work. Mr. Ashutosh Kumar Mr. Dheeraj Sangur Mr. Kushal Bendigiri Mr. Vishwanath Reddy

INDEX PAGE NO.

  • 1.1 Introduction to the project 1. Introduction
  • 1.2 Introduction to Computer Graphics...............................................................
  • 1.3 History of Computer Graphics.......................................................................
  • 1.4 Application of Computer Graphics................................................................
  • 1.5 Introduction to OpenGL.................................................................................
  • 1.6 Introduction to GLUT....................................................................................
  • 1.7 Application of OpenGL..................................................................................
  • 1.8 OpenGL primitives.........................................................................................
  • 2.1 Software requirements…............................................................................... 2. System Requirements
  • 2.2 Hardware requirements..................................................................................
    • 3.1 Three Dimensional Transformations................................................................ 3. System Design
    • 3.2 Flow Analysis..................................................................................................
    • 3.3 Sequence Diagram..........................................................................................
    • 4.1 Built-In Functions.......................................................................................... 4. Implementation
    • 4.2 User-Defined Functions.................................................................................
    • 4.3 Source Code...................................................................................................
      1. Testing.....................................................................................................................
    1. Snapshots...............................................................................................................
    • Conclusion..................................................................................................................
    • Future Enhancements..................................................................................................
    • Bibliography...............................................................................................................

Windmill

Chapter 1

INTRODUCTION

1.1 Introduction to the project

The mini project “ Windmill ” demonstrate the functionality of windmill machine which converts the energy of the wind into rotational energy by means of vanes known as sails. Based on history, the windmill machinery was adapted to many other industrial uses. Wind mill was built to generate electricity for the use of the water pump. Windmill is a good source of green energy because it can generate a huge amount of electricity in low cost, take up only a small plot of land, is very friendly to the environment, create an interesting feature to the landscape, available in variety of sizes. In the first frame we have shown the entire setup for electricity generation using windmills and a power station which simultaneously converts wind’s rotational energy into power generation. The last and final frame depicts the movement of windmill’s blades in respective directions which produce electricity in power station and from their it is supplied to various households and street lights. The entire setup is been achieved using openGL functions and glut library files.

1.2 Introduction to Computer Graphics

Computer Graphics is concerned with all aspects of producing pictures or images using a computer. We can create images that are indistinguishable from photographs of real objects. In other terms, Computer Graphics are the graphics created by the computers, and more generally, the representation and manipulation of image data by a computer. The development of computer graphics has been driven both by the needs of the user community and by advances in hardware and software. Typically, the term Computer Graphics refers to several different things:  The representation and manipulation of image data by a computer.  The various technologies used to create and manipulate images.  The images so produced, and manipulating visual content. DEPT OF CSE, KLEIT, HUBLI Page 1

Windmill

1.3 History of Computer Graphics

Further advances in computing led to greater advancements in interactive computer graphics. In 1959, the TX-2 computer was developed at MIT's Lincoln Laboratory. A light pen could be used to draw sketches on the computer using Ivan Sutherland’s revolutionary Sketchpad software. Also in 1961 another student at MIT, Steve Russell, created the first video game, Spacewar. E. E. Zajac, a scientist at Bell Telephone Laboratory (BTL), created a film called "Simulation of a two-giro gravity attitude control system" in 1963. In this computer generated film, Zajac showed how the attitude of a satellite could be altered as it orbits the Earth. Many of the most important early breakthroughs in computer graphics research occurred at the University of Utah in the 1970s. The first major advance in 3D computer graphics was created at UU by these early pioneers, the hidden-surface algorithm. In order to draw a representation of a 3D object on the screen, the computer must determine which surfaces are "behind" the object from the viewer's perspective, and thus should be "hidden" when the computer creates (or renders) the image. Graphics and application processing were increasingly migrated to the intelligence in the workstation, rather than continuing to rely on central mainframe and mini-computers. 3D graphics became more popular in the 1990s in gaming, multimedia and animation. Computer graphics used in films and video games gradually began to be realistic to the point of entering the uncanny valley.

1.4 Applications of Computer Graphics

The development of computer graphics has been driven both by the needs of the user community and by advances in hardware and software. The applications of computer graphics are many and varied. We can however divide them into four major areas. Display of information: More than 4000 years ago, the Babylonians developed floor plans of buildings on stones. Today, the same type of information is generated by architects using computers. Over the past 150 years, workers in the field of statistics have explored techniques for generating plots. Now, we have DEPT OF CSE, KLEIT, HUBLI Page 2

Windmill In addition to being language-independent, OpenGL is also platform-independent. The specification says nothing on the subject of obtaining, and managing, an OpenGL context, leaving this as a detail of the underlying windowing system. For the same reason, OpenGL is purely concerned with rendering, providing no APIs related to input, audio, or windowing. OpenGL is an evolving API. New versions of the OpenGL specification are regularly released by the Khronos Group, each of which extends the API to support various new features. In addition to the features required by the core API, GPU vendors may provide additional functionality in the form of extensions. Extensions may introduce new functions and new constants, and may relax or remove restrictions on existing OpenGL functions. Vendors can use extensions to expose custom APIs without needing support from other vendors or the Khronos Group as a whole, which greatly increases the flexibility of OpenGL. All extensions are collected in, and defined by, the OpenGL Registry. Fig 1.1 OpenGL Pipeline

1.6 Introduction to GLUT

GLUT is the OpenGL utility toolkit, a window system independent toolkit for writing OpenGL programs. It implements a simple windowing API for OpenGL. GLUT makes it easier to learn DEPT OF CSE, KLEIT, HUBLI Page 4

Windmill about and explore OpenGL programming. GLUT provides a portable API so you can write a single OpenGL program that works across all PC and workstation OS platforms. GLUT is designed for constructing small to medium sized OpenGL programs. While GLUT is well-suited to learning OpenGL and developing simple OpenGL applications, GLUT is not a full-featured toolkit so large applications requiring sophisticated user interfaces are better off using native window system toolkits. The GLUT library has C, C++ (same as C), FORTRAN, and ADA programming bindings. The GLUT source code distribution is portable to nearly all OpenGL implementations and platforms. Fig 1.2 Library Organisation of OpenGL

1.7 Applications of OpenGL

OpenGL ( O pen G raphics L ibrary) is a cross-language, multi-platform API for Rendering 2D and 3D computer graphics. The API is typically used to interact with a GPU, to achieve hardware- Accelerated rendering. It is widely used in CAD, virtual reality, scientific visualization, information DEPT OF CSE, KLEIT, HUBLI Page 5

Windmill

Chapter 2

SYSTEM REQUIREMENTS

Hardware Requirements:

 Processor : Intel dual core i3 and above.  RAM : 1GB RAM or above.  Input devices: Keyboard.  Output devices: Monitor.

Software Requirements:

 Software: Microsoft Visual Studio 2010.  Operating system : Windows 10.  glut.h header files.  glut.dll library files. DEPT OF CSE, KLEIT, HUBLI Page 7

Windmill

Chapter 3

SYSTEM DESIGN

The designing of project windmill is being done with the help of three dimensional transformation concepts of translation, scaling and rotation.

3.1 Three Dimensional Transformations

3D Translation

It is the movement of an object from one position to another position. Translation is done using translation vectors. There are three vectors in 3D instead of two. These vectors are in x, y, and z directions. Translation in the x-direction is represented using Tx. The translation is y-direction is represented using Ty. The translation in the z- direction is represented using Tz.

3D Scaling

Scaling is used to change the size of an object. The size can be increased or decreased. The scaling three factors are required Sx Sy and Sz. Sx=Scaling factor in x- direction Sy=Scaling factor in y-direction Sz=Scaling factor in z-direction

3D Rotation

DEPT OF CSE, KLEIT, HUBLI Page 8

Windmill

3.2 Flow Analysis..................................................................................................

The flow analysis of project windmill discusses the interaction of a user with the scene i.e. user interface and also the changes that will happen in the scene when a user selects appropriate options.  The program execution starts with main scene which describes the details of windmill project. The user can continue by clicking mouse right button which will pop up the respective options and by selecting any one of them, user goes to respective scene.  The options which will be pop once user do ‘right click’ of mouse are:  No Wind  Wind CW  Fast Wind CW  Wind ACW  Fast Wind ACW  Quit  On selecting ‘No Wind’ option, the scene displays no movement of windmills and clouds. Therefore the electricity is not generated and the light in powerhouse, huts and streetlights will not glow up.  On selecting ‘Wind CW’ option, the scene displays the slow clockwise rotation of windmills along the direction of movement of clouds. The user can observe that electricity is being generated and the light in powerhouse and huts will glow up but streetlights will remain off.  On selecting ‘Fast Wind CW’ option, the scene displays the fast clockwise rotation of windmills along the direction of movement of clouds. The user can observe that electricity is being generated and the light in powerhouse, huts and streetlights will glow up.  On selecting ‘Wind ACW’ option, the scene displays the slow anticlockwise rotation of windmills along the direction of movement of clouds. The user can observe that electricity is DEPT OF CSE, KLEIT, HUBLI Page 10

Main scene displayed Windmill being generated and the light in powerhouse and huts will glow up but streetlights will remain off.  On selecting ‘Fast Wind ACW’ option, the scene displays the fast anticlockwise rotation of windmills along the direction of movement of clouds. The user can observe that electricity is being generated and the light in powerhouse, huts and streetlights will glow up.  On selecting ‘Quit’ option, the user will come out of the scene.

3.3 Sequence Diagram..........................................................................................

DEPT OF CSE, KLEIT, HUBLI Page 11 Start ‘Right Click’ of mouse