Search Projects

Friday, May 22, 2020

वट सावित्री व्रत ओपनजीएल प्रोजेक्ट्स


वटसावित्री व्रत

इस दिन वट यानी बरगद के पेड़ की पूजा की जाती है। कहा जाता है कि वट वृक्ष की जड़ों में ब्रह्मा, तने में भगवान विष्णु व डालियों व पत्तियों में भगवान शिव का निवास स्थान माना जाता है। व्रत रखने वालों को मां सावित्री और सत्यवान की कथा पढ़ना या सुनना जरूरी होता है।

यह व्रत विशेषकर विवाहित महिलाओं के द्वारा अखंड सौभाग्य का आशीर्वाद पाने के लिए रखा जाता है। धार्मिक मान्यता के अनुसार, यदि कोई शादीशुदा महिला इस व्रत को सच्चे मन से करती है तो उसका पति दीर्घायु होता है। हिन्दू पंचांग के अनुसार यह व्रत हर साल ज्येष्ठ माह की अमावस्या तिथि के दिन रखा जाता है। आइए जानते हैं इस व्रत का शुभ मुहूर्त और व्रत विधि।

मान्यता है कि इस दिन माता सावित्री ने अपने दृढ़ संकल्प और श्रद्धा से यमराज द्वारा अपने मृत पति सत्यवान के प्राण वापस पाए। इसलिए महिलाओं के लिए ये व्रत बेहद ही फलदायी माना जाता है।


यह प्रोजेक्ट शीघ्र ही प्रकाशित होनेवाली है।

Friday, May 1, 2020

Super Pink Moon 2020

INTRODUCTION


A Super Moon occurs when full Moon in its orbit is at the nearest distance to the Earth. The super moon looks 14% larger than regular full moon and it is 30% more brighter. 
Astrologer Richard Nolle was first to define super moon in 1979. According to him a full moon or a new moon which comes at 90% closed proximity to the Earth termed as super moon. To know more about super moon in depth visit NASA article on Super moon.
This time around, we're getting what people often call a 'super moon' as well as a full Moon, because the Moon will be in perigee: the closest possible point to us in its elliptic orbit, a mere 357,035 kilometres or 221,851 miles away from Earth.





















And, as we well know, super moons tend to attract quite a bit of poetry. This time around, the event is also being referred to as 'pink' thanks to the beautiful Pink Phlox flowers that bloom in spring in the US and Canada.

Even if it's not going to loom pink, we think looking up at the night skies to admire the bright ball may give us all a few minutes of respite from worrying about these trying times that we're all going through.

It won't actually be pink, but it will appear to be the biggest and brightest of all the full Moons of 2020.

The pink super moon will be visible in the night skies over Australia on the evening of Wednesday 8 April. If you're following in the UK, the brightness peak will be in the early hours of April 8, and for US moon-watchers the best time to get out and look up is the evening of Tuesday 7 April. In India the peak would be on 8th April, morning 8:05am.

As it happens, we're actually in the middle of a run of super moons right now, with March, April and May all having one. If you miss this one, you won't have to wait long for the next opportunity.

Moon Orbit - apogee and Perigee


  1. The Moon orbits Earth in an ellipse, an oval that brings it closer to and farther from Earth as it goes around.
  2. The farthest point in this ellipse is called the apogee and is about 253,000 miles (405,500 kilometres) from Earth on average.
  3. Its closest point is the perigee, which is an average distance of about 226,000 miles (363,300 kilometres) from Earth.
  4. When a full moon appears at perigee it is slightly brighter and larger than a regular full moon—and that's where we get a "super moon".




How many Super moons in a year?

There can be 3-4 new moon, even 3-4 full moon in a year which termed to be super moon.
The different types of moons
Here are some of the most interesting moon phases and when to see them... A Blue Moon refers to the occasion when a full moon appears for the second time in the same month, this is very rare and the next Blue Moon should occur on Halloween in 2020.The Harvest Moon appears around the time of the autumnal equinox when farmers tend to do their main crop harvesting.A Super moon appears when it is at its closest point to Earth and therefore at its brightest, the next one will appear in September.A Blood Moon occurs during a total lunar eclipse, the next one should happen in May 2020.Each month of the year actually has its own special full moon phenomenon, they are as follows: 

January: Wolf Moon
February: Snow Moon
March: Worm Moon
April: Pink Moon
May: Flower Moon
June: Strawberry Moon
July: Buck Moon
August: Sturgeon Moon
September: Full Corn Moon
October: Hunter's Moon
November: Beaver Moon
December: Cold Moon.




Monday, March 30, 2020

Electromagnetic induction demo with opengl graphic program

Electromagnetic induction or magnetic induction or simply induction is process in which electric current or voltage is passed through a conductor when it is placed in postion around varying magnetic field. Induction also produce current when a conducting material constantly moves around a static magnetic field. The current run through conducting material due to electromagnetic force. Michael Faraday has been credited for discoverey of  Law of Induction in 1831. The laws is now called Faraday laws of Electromagnetic induction. We are going demo with help of computer graphics how Electromagnetic induction work. The graphic will be coded in c++ with opengl graphic library.


Abstract


With help of opengl program computer graphics we are going to demo the Electromagnetic induction. 




Faraday laws of Electromagnetic induction.

Before we get into details of the program first you need to understand what Faraday laws of Electromagnetic induction is all about. This will help us in properly demo the Electromagnetic induction with opengl program graphically.


There are two faraday's law of electromagnetic induction as stated below - 
  1. First law : change in magnetic flux linked with a closed coil, an induced emfis  produced and current flows through the coil. This induced e.m.f. remains till the flux changes. 
  2. Second law : The induced emf in a coil is equal to the rate of change of flux linkage.
There are many things like equation, maxwell farady law, Lenz law, right thumb rule but we will not focus on them.

There are many application of  Electromagnetic induction including electrical components such as inductors and transformers, and devices such as electric motors and generators. The ATM swipe in pos also use the Electromagnetic induction.

Description of opengl program

Our opengl program demo Electromagnetic induction graphically. We are going to code the program with user interface. 

The opengl program will create two basic model one for static magnet another for rotating magnet. First a wireframe cylinder is needed which will act as conductor or coil. This coil then attached to spherical object which is bulb. A rectangular magnet is also designed. When magnet is place in coil the emf is produced and bulb glows as current runs in coil. Color of sphere is black when there is no current and for current same will change to yellow.

In another scenario we will rotate magnet and produce current. Rapid movement of magnet can be shown using pencils like cone with rectangular middle. 


User Interface

Following keyboard interface and functionity as given below is used in this opengl program - 

'S/s' key - start the program
'M/m' key - move the magnet
'T/t' key - toggle
'F/f' key - increase the flow
'Esc/e/E' key - to exit any time.

Email us @ openglprojects@gmail.com for source code and reports.

Monday, January 14, 2019

The Classroom CG lab Programs VTU

Preface 

OpenGL is used in the CG lab Programs VTU 6th SEM for learning the graphics. The aim of this blog is to give as much exposure to students so they can learn create and explore the new ideas of implementing the Computer graphics.

We have share many projects with free source code. We have also provided the free opengl tutorials in our blog. We have shre multiple programs snippets of c/c++ source code in OpenGL. There are many simple projects that can be used for large program with some library based program that can be complex in nature. With the same aim we have come up a program that act as the first part of our complex journey. We name the Program as  - "The Classroom".



Introduction

The Classroom CG lab Programs for VTU 6th SEM student comprised of showing jouney of education when we all are child and start learning the basics. This program will show the graphical representation of the the classroom where a teacher try to teaches student "A for apple B for Ball ...".

Components

CG lab Programs which  we have come up with have so many components or functions. These functions are basically code for small objects like roof, floor, blackboard tube light etc. Different parts of the classroom have different functions to create the objects.

We have created the lady teachers by using the different objects. Like the face we have used the circle to draw it. Similarly the hair we use the semi circle (created code for it). The other parts like nose we have use the lines and vertices with proper coordinates.

There are four kids which are facing towards the teachers has been rendered in this The Classroom CG lab Programs VTU 6th SEM. We have created two benches and each benches consist of two students. 

There is dark mode of the program where you can switch off the tubelight and whole class would be in dark.

User Interactions

n - to continues form start screen and proceed to next.
b- back to previous screen
r- restart the screen

Video Demo


Source Code

To get the source code write to openglprojects@gmail.com with the project title.

Sunday, August 26, 2018

OpenGL Chess Board in C++ with Source Code

Chess is interesting game with 8X8 checker of black and white. Hence we are going to see a program in OpenGL that implement Chess Board in C++ with free Source Code.

This program implements with the three functions:

1. Init function - this initalise the opengl program.
2. Chess Boards - this calculate the chess and sqaure and draw the same in the screen.
3.  Main function - this is the must and common program for each and every oepngl program.

chessboard() this function is used for the calculation of the end point of the cordinates of the box to make and is also mainly responsible for calling the drawSquare()
It is also a display function which is called from the main function which is responsible for sending graphics to the display window.

The forming of boxes is made through iterating first of all from 1st row and making 1st column then 2nd and then till 8th column as a single chessbord contains 8 column.

The similiar above operation is repeated till all the 8 rows have been iterated making a total 64 boxes (8 rows and 8 column).

The finally the chessboard() function contains a opengl glFlush()  which process all opengl routine as quickly as possible means it flushes all the matter on the display window for the next display.

This similar to our earlier chess board opengl program.

USE OF THE PROGRAM:

        The program OpenGL Chess Board in C++ can be use in the chess board game as well as in making the floor of the house or any other structure.

Source Code : 


#include<windows.h>
#include<glut.h>
int c = 0;
void init()
{
// For displaying the window color
glClearColor(0, 1, 1, 0);
// Choosing the type of projection
glMatrixMode(GL_PROJECTION);
// for setting the transformation which here is 2D
gluOrtho2D(0, 800, 0,600);
}

void drawSquare(GLint x1, GLint y1, GLint x2, GLint y2, GLint x3, GLint y3, GLint x4, GLint y4)
{
// if color is 0 then draw white box and change value of color = 1
if (c == 0)
{
glColor3f(1, 1, 1); // white color value is 1 1 1
c = 1;
}
// if color is 1 then draw black box and change value of color = 0
else
{
glColor3f(0, 0, 0); // black color value is 0 0 0
c = 0;
}

// Draw Square
glBegin(GL_POLYGON);
glVertex2i(x1, y1);
glVertex2i(x2, y2);
glVertex2i(x3, y3);
glVertex2i(x4, y4);
glEnd();
}
void chessboard()
{
glClear(GL_COLOR_BUFFER_BIT); // Clear display window
GLint x, y;

for (x = 0; x <= 800; x += 100)
{
for (y = 0; y <= 600; y += 75)
{
drawSquare(x, y + 75, x + 100, y + 75, x + 100, y, x, y);
}
}
// Process all OpenGL routine s as quickly as possible
glFlush();
}

int main(int agrc, char ** argv)
{
// Initialize GLUT
glutInit(&agrc, argv);
// Set display mode
glutInitDisplayMode(GLUT_SINGLE | GLUT_RGB);
// Set top - left display window position.
glutInitWindowPosition(100, 100);
// Set display window width and height
glutInitWindowSize(800, 600);
// Create display window with the given title
glutCreateWindow("Chess Board using OpenGL in C++");
// Execute initialization procedure
init();
// Send graphics to display window
glutDisplayFunc(chessboard);
// Display everything and wait.
glutMainLoop();
}