CGI Manual @vtuupdates Com
CGI Manual @vtuupdates Com
PART A
Program 1: Develop a program to draw a line using Bresenham’s line drawing technique
Program Objective:
• creation of 2D objects
• Implement GLU and GLUT functions
To have the detailed knowledge of the graphics Bresenham’s line algorithm.
#include<GL/glut.h>
#include<stdio.h>
int x1,x2,y1,y2; void
myInit()
{ glClearColor(0.0,0.0,0.0,0.0);
glMatrixMode(GL_PROJECTION);
glLoadIdentity(); gluOrtho2D(0,500,0,500);
}
void draw_pixel(int x,int y)
{
glBegin(GL_POINTS);
glVertex2i(x,y);
glEnd(); }
void draw_line(int x1,int x2,int y1,int y2)
{ int dx,dy,i,e; int
incx,incy,inc1,inc2;
int x,y;
dx=x2-x1;
dy=y2-y1;
if(dx<0) dx=-dx;
if(dy<0) dy=-dy;
incx=1;
if(x2<x1) incx=-
1; incy=1;
if(y2<y1) incy=-
1; x=x1; y=y1;
if(dx>dy) {
draw_pixel(x,y);
e=2*dy-dx;
inc1=2*(dy-dx);
inc2=2*dy;
for(i=0;i<dx;i++)
{
if(e>=0) {
y+=incy;
e+=inc1; } else
e+=inc2;
x+=incx;
draw_pixel(x,y);
www.vtuupdates.com Page 1
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
} } else {
draw_pixel(x,y);
e=2*dx-dy;
inc1=2*(dx-dy);
inc2=2*dx;
for(i=0;i<dy;i++)
{ if(e>=0) {
x+=incx;
e+=inc1; } else
e+=inc2;
y+=incy;
draw_pixel(x,y);
}
}
} void
myDisplay()
{
glClear(GL_COLOR_BUFFER_BIT);
draw_line(x1,x2,y1,y2); glFlush(); }
int main(int argc,char **argv)
{
printf("enter x1,x2,y1,y2\n");
scanf("%d%d%d%d",&x1,&x2,&y1,&y2);
glutInit(&argc,argv);
glutInitDisplayMode(GLUT_SINGLE | GLUT_RGB);
glutInitWindowSize(500,500);
glutInitWindowPosition(0,0);
glutCreateWindow("win");
glutDisplayFunc(myDisplay);
myInit();
glEnable(GL_DEPTH_TEST);
glClearColor(0.0,0.0,0.0,0.0);
glutMainLoop();
}
RUN:
g++ 1.cpp -lglut -lGL –lGLU
./a.out
OUTPUT:
www.vtuupdates.com Page 2
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
s
Program Outcome:
Ability to Design and develop 2D objects for different graphics applications.
Use matrix algebra in computer graphics and implement Brenham's line algorithm.
Analyze and evaluate the use of openGL methodss in practical applications of 2D
representations.
www.vtuupdates.com Page 3
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
creation of 2D objects
• Create 2D objects with basic transformation operations like translation, rotation, scaling.
• Use mathematical and theoretical principles i.e. transformation matrices of computer
graphics to draw and translate, rotate, scaled object.
#include <GL/glut.h>
#include <iostream>
void init() {
glClearColor(1.0, 1.0, 1.0, 0.0);
glMatrixMode(GL_PROJECTION);
gluOrtho2D(-300.0, 300.0, -300.0, 300.0);
}
void drawRectangle() {
glPushMatrix();
glTranslatef(translateX, translateY, 0.0);
glRotatef(rotateAngle, 0.0, 0.0, 1.0);
glScalef(scaleX, scaleY, 1.0);
glPopMatrix();
}
void display() {
glClear(GL_COLOR_BUFFER_BIT);
www.vtuupdates.com Page 4
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
drawRectangle();
glFlush();
}
void keyboard(unsigned char key, int x, int y) {
switch (key) { case 't':
translateX += 10.0f;
translateY += 10.0f;
break;
case 'r':
rotateAngle += 10.0f;
break;
case 's':
scaleX += 0.1f;
scaleY += 0.1f;
break;
}
glutPostRedisplay();
}
init();
glutDisplayFunc(display);
glutKeyboardFunc(keyboard);
glutMainLoop();
return 0;
}
RUN:
./a.out
This program creates a rectangle using OpenGL and demonstrates three basic geometric
operations:
1. Translation: Press 't' to translate the rectangle by 10 units in both the x and y directions.
2. Rotation: Press 'r' to rotate the rectangle by 10 degrees clockwise around its center.
3. Scaling: Press 's' to scale the rectangle by 0.1 in both the x and y directions.
www.vtuupdates.com Page 5
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Compile and run this program, then press the respective keys to perform the geometric
operations. You should see the rectangle change accordingly on the screen.
OUTPUT:
www.vtuupdates.com Page 6
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
• creation of 3D objects
• Create 3D object with basic transformation operations like translation, rotation, scaling.
• Use mathematical and theoretical principles i.e. transformation matrices of computer graphics to
draw and translate, rotate, scaled object.
#include<GL/glut.h>
#include<stdio.h>
GLfloat vertices[][3]={{-1.0,-1.0,-1.0},{1.0,-1.0,-1.0},{1.0,1.0,-1.0},{-1.0,1.0,-1.0},{-1.0,-
1.0,1.0},{1.0,-1.0,1.0},{1.0,1.0,1.0},{-1.0,1.0,1.0}};
GLfloat
colors[][3]={{0.0,0.0,0.0},{0.0,0.0,1.0},{0.0,1.0,0.0},{0.0,1.0,1.0},{1.0,0.0,0.0},{1.0,0.0,1.0},{1.
0,1.0,0.0},{1.0,1.0,1.0}};
static GLfloat theta[]={0.0,0.0,0.0};
static GLint axis=2; static
GLdouble viewer[]={0,0,5};
void polygon(int a,int b,int c,int d)
{
glBegin(GL_POLYGON);
glColor3fv(colors[a]);
glVertex3fv(vertices[a]);
glColor3fv(colors[b]);
glVertex3fv(vertices[b]);
glColor3fv(colors[c]);
glVertex3fv(vertices[c]);
glColor3fv(colors[d]);
glVertex3fv(vertices[d]);
glEnd(); }
void colorcube()
{ polygon(0,3,2,1);
polygon(2,3,7,6);
polygon(1,2,6,5);
polygon(0,4,5,1);
polygon(4,5,6,7);
polygon(0,3,7,4);
}
void display()
{
glClear(GL_COLOR_BUFFER_BIT|GL_DEPTH_BUFFER_BIT); glLoadIdentity();
glRotatef(theta[0],1.0,0.0,0.0);
glRotatef(theta[1],0.0,1.0,0.0);
glRotatef(theta[2],0.0,0.0,1.0);
colorcube(); glFlush();
glutSwapBuffers();
}
www.vtuupdates.com Page 7
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
void spincube()
{ theta[axis]+=2.0;
if(theta[axis]>360.0)
theta[axis]-=360.0;
glutPostRedisplay();
}
void mouse(int btn,int state,int x,int y)
{
if(btn==GLUT_LEFT_BUTTON&&state==GLUT_DOWN) axis=0;
if(btn==GLUT_MIDDLE_BUTTON&&state==GLUT_DOWN) axis=1;
if(btn==GLUT_RIGHT_BUTTON&&state==GLUT_DOWN)
axis=2; spincube(); }
void myreshape(int w,int h)
{
glViewport(0,0,w,h); glMatrixMode(GL_PROJECTION);
glLoadIdentity(); if(w<=h)
glOrtho(-2.0,2.0,-2.0*(GLfloat)h/(GLfloat)w,2.0*(GLfloat)h/(GLfloat)w,-10.0,10.0); else
glOrtho(-2.0*(GLfloat)w/(GLfloat)h,2.0*(GLfloat)w/(GLfloat)h,-2.0,2.0,-10.0,10.0);
glMatrixMode(GL_MODELVIEW);
glutPostRedisplay();
}
int main(int argc,char**argv)
{
glutInit(&argc,argv);
glutInitDisplayMode(GLUT_DOUBLE|GLUT_RGB|GLUT_DEPTH);
glutCreateWindow("3D object Geometric Operations in OpenGL ");
glutReshapeFunc(myreshape); glutDisplayFunc(display);
glutIdleFunc(spincube); glutMouseFunc(mouse);
glEnable(GL_DEPTH_TEST); glClearColor(0.0,0.0,0.0,0.0);
glutMainLoop(); return
0;
}
RUN:
g++ 3.cpp -lglut -lGL –lGLU
./a.out
OUTPUT:
www.vtuupdates.com Page 8
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Outcome:
www.vtuupdates.com Page 9
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
• creation of 2D objects
• Create 2D objects with basic transformation operations like translation, rotation, scaling.
• Use mathematical and theoretical principles i.e. transformation matrices of computer
graphics to draw and rotate the color cube object.
• Use matrix algebra in computer graphics and implement fundamental algorithms and
transformations involved in viewing models.
#include <GL/glut.h>
#include <cmath>
// Object properties
struct Object {
float x; float
y; float size;
};
// Transformation properties
float translateX = 0.0f; float
translateY = 0.0f; float
rotateAngle = 0.0f; float
scaleX = 1.0f; float scaleY
= 1.0f;
void init() {
glClearColor(1.0, 1.0, 1.0, 0.0);
glMatrixMode(GL_PROJECTION);
gluOrtho2D(-300.0, 300.0, -300.0, 300.0);
}
www.vtuupdates.com Page 10
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
glPopMatrix();
}
glPushMatrix(); glTranslatef(x, y,
0.0); glRotatef(rotateAngle, 0.0, 0.0,
1.0);
glScalef(scaleX, scaleY, 1.0);
glPopMatrix();
}
void display() {
glClear(GL_COLOR_BUFFER_BIT);
glFlush();
}
www.vtuupdates.com Page 11
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
case 't':
translateX += 10.0f;
translateY += 10.0f;
break;
case 'r':
rotateAngle += 10.0f;
break;
case 's':
scaleX += 0.1f;
scaleY += 0.1f; break;
}
glutPostRedisplay();
}
init();
glutDisplayFunc(display);
glutKeyboardFunc(keyboard);
glutMainLoop();
return 0;
}
RUN:
g++ 4.cpp -lglut -lGL –lGLU
./a.out
www.vtuupdates.com Page 12
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
Program Outcome:
Program Objective:
www.vtuupdates.com Page 13
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
• creation of 3D objects
• Create 3D objects with basic transformation operations like translation, rotation, scaling.
• Use mathematical and theoretical principles i.e. transformation matrices of computer
graphics to draw and rotate the color cube object.
• Use matrix algebra in computer graphics and implement fundamental algorithms and
transformations involved in viewing models.
#include <GL/glut.h>
#include <iostream>
// Back face
glColor3f(0.0f, 1.0f, 0.0f); // Green
glVertex3f(-0.5f, -0.5f, -0.5f); glVertex3f(-
0.5f, 0.5f, -0.5f); glVertex3f(0.5f, 0.5f, -0.5f);
glVertex3f(0.5f, -0.5f, -0.5f);
// Bottom face
glColor3f(1.0f, 1.0f, 0.0f); // Yellow glVertex3f(-
0.5f, -0.5f, -0.5f); glVertex3f(0.5f, -0.5f, -0.5f);
glVertex3f(0.5f, -0.5f, 0.5f);
glVertex3f(-0.5f, -0.5f, 0.5f);
www.vtuupdates.com Page 14
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
// Right face
glColor3f(1.0f, 0.0f, 1.0f);
// Magenta
glVertex3f(0.5f, -0.5f, -0.5f);
glVertex3f(0.5f, 0.5f, -0.5f);
glVertex3f(0.5f, 0.5f, 0.5f);
glVertex3f(0.5f, -0.5f, 0.5f);
// Left face
glColor3f(0.0f, 1.0f, 1.0f);
// Cyan
glVertex3f(-0.5f, -0.5f, -0.5f);
glVertex3f(-0.5f, -0.5f, 0.5f);
glVertex3f(-0.5f, 0.5f, 0.5f);
glVertex3f(-0.5f, 0.5f, -0.5f);
glEnd();
}
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
// Apply transformations
//glTranslatef(0.0f, 0.0f, -3.0f);
glTranslatef(translateX, 0.0f, -3.0f);
glTranslatef(0.0f, translateY, -3.0f);
glRotatef(rotationX, 1.0f, 0.0f, 0.0f);
glRotatef(rotationY, 0.0f, 1.0f, 0.0f);
glScalef(scale, scale, scale);
// Draw cube
drawCube();
glutSwapBuffers();
}
www.vtuupdates.com Page 15
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
break; case
'X': rotationX -=
5.0f;
break;
case 'z':
rotationY += 5.0f;
break;
case 'Z':
rotationY -= 5.0f;
break;
case '+': scale
+= 0.1f; break;
case '-': if
(scale > 0.1f)
scale -= 0.1f;
break; case 't':
translateX += 0.5f;
break; case 'T':
translateX -= 0.5f;
break; case 'y':
translateY += 0.5f;
break; case 'Y':
translateY -= 0.5f;
break;
case 27: // Escape key to exit
exit(0);
break;
}
glEnable(GL_DEPTH_TEST);
glClearColor(1.0f, 1.0f, 1.0f, 1.0f); // White background
glMatrixMode(GL_PROJECTION);
glLoadIdentity();
gluPerspective(45.0f, (float)width / (float)height, 1.0f, 100.0f);
glutDisplayFunc(display);
glutKeyboardFunc(keyboard);
}
www.vtuupdates.com Page 16
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
RUN:
g++ 5.cpp -lglut -lGL –lGLU
./a.out
OUTPUT:
www.vtuupdates.com Page 17
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
#include <GL/glut.h>
#include <math.h>
#include <stdlib.h>
void displayHex(void)
{
glClear(GL_COLOR_BUFFER_BIT);
glPushMatrix( );
glRotatef(rotTheta, 0.0, 0.0, 1.0);
glCallList(regHex);
glPopMatrix( );
www.vtuupdates.com Page 18
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
glutSwapBuffers( ); glFlush(
);
}
void rotateHex(void)
{ rotTheta += 3.0;
if(rotTheta > 360.0)
rotTheta -= 360.0;
glutPostRedisplay( );
}
void winReshapeFcn(GLint newWidth, GLint newHeight)
{
glViewport(0, 0,(GLsizei) newWidth,(GLsizei) newHeight);
glMatrixMode(GL_PROJECTION);
glLoadIdentity( ); gluOrtho2D(-320.0,
320.0, -320.0, 320.0);
glMatrixMode(GL_MODELVIEW);
glLoadIdentity( );
glClear(GL_COLOR_BUFFER_BIT);
}
void mouseFcn(GLint button, GLint action, GLint x, GLint y)
{ switch(button) { case
GLUT_MIDDLE_BUTTON:
// Start the rotation.
if(action == GLUT_DOWN)
glutIdleFunc(rotateHex); break;
case GLUT_RIGHT_BUTTON:
// Stop the rotation.
if(action == GLUT_DOWN)
glutIdleFunc(NULL);
break;
default:
break;
}
}
www.vtuupdates.com Page 19
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
RUN:
g++ 6.cpp -lglut -lGL –lGLU
./a.out
OUTPUT:
Program Outcome:
www.vtuupdates.com Page 20
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
7: Write a Program to read a digital image. Split and display image into 4
quadrants, up, down, right and left
Program Objective:
cv2.waitKey(0)
cv2.destroyAllWindows()
www.vtuupdates.com Page 21
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
Program Outcome:
• Ability to read a digital image. Split and display image into 4 quadrants, up, down, right
and left
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
import cv2
import numpy as np
www.vtuupdates.com Page 23
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
Program Outcome:
9: Read an image and extract and display low-level features such as edges,
textures using filtering techniques.
Program Objective:
import cv2
import numpy as np
# Edge detection
edges = cv2.Canny(gray, 100, 200) # Use Canny edge detector
www.vtuupdates.com Page 25
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
Program Outcome:
• Ability to read an image and extract and display low-level features such as edges, textures
using filtering techniques.
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
import cv2
# Gaussian Blur
gaussian_blur = cv2.GaussianBlur(image, (5, 5), 0)
# Median Blur
median_blur = cv2.medianBlur(image, 5)
# Bilateral Filter
bilateral_filter = cv2.bilateralFilter(image, 9, 75, 75)
www.vtuupdates.com Page 27
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
Program Objective:
import cv2
import numpy as np
# Find contours
contours, hierarchy = cv2.findContours(thresh, cv2.RETR_EXTERNAL,
cv2.CHAIN_APPROX_SIMPLE)
www.vtuupdates.com Page 29
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
Program Outcome:
Program Objective:
import cv2
www.vtuupdates.com Page 31
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
OUTPUT:
Program Outcome:
• Able to detect a face in any given image Step 1: Import the OpenCV Package.
• Step 2: Read the Image.
• Step 3: Convert the Image to Grayscale.
• Step 4: Load the Classifier.
• Step 5: Perform the Face Detection.
• Step 6: Drawing a Bounding Box.
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
PART B
Practical Based Learning:
Student should develop a mini project and it should be demonstrate in the laboratory
examination, some of the projects are listed and it is not limited to:
Recognition of License Plate through Image Processing
Recognition of Face Emotion in Real-Time
Detection of Drowsy Driver in Real-Time
Recognition of Handwriting by Image Processing
Detection of Kidney Stone
Verification of Signature
Compression of Color Image
Classification of Image Category
Detection of Skin Cancer
Marking System of Attendance using Image Processing
Detection of Liver Tumor
IRIS Segmentation
Detection of Skin Disease and / or Plant Disease Biometric Sensing System.
Projects which helps to formers to understand the present developments in agriculture
Projects which helps high school/college students to understand the scientific problems.
Simulation projects which helps to understand innovations in science and technology
CO 2: Analyze the necessity mathematics and design required to demonstrate basic geometric
transformation techniques.
C0 4: Apply the concepts to Develop user friendly applications using Graphics and IP concepts.
Assessment Details (both CIE and SEE)
www.vtuupdates.com Page 33
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
The weightage of Continuous Internal Evaluation (CIE) is 50% and for Semester End Exam (SEE)
is 50%. The minimum passing mark for the CIE is 40% of the maximum marks (20 marks). A
student shall be deemed to have satisfied the academic requirements and earned the credits allotted
to each course. The student has to secure not less than 35% (18 Marks out of 50) in the semester-
end examination (SEE).
Continuous Internal Evaluation (CIE):
CIE marks for the practical course is 50 Marks.
The split-up of CIE marks for record/ journal and test are in the ratio 60:40.
• Each experiment to be evaluated for conduction with observation sheet and record writeup.
Rubrics for the evaluation of the journal/write-up for hardware/software experiments
designed by the faculty who is handling the laboratory session and is made known to
students at the beginning of the practical session.
• Record should contain all the specified experiments in the syllabus and each experiment
write-up will be evaluated for 10 marks.
• Total marks scored by the students are scaled downed to 30 marks (60% of maximum
marks).
• Weightage to be given for neatness and submission of record/write-up on time.
• Department shall conduct 02 tests for 100 marks, the first test shall be conducted after the
8th week of the semester and the second test shall be conducted after the 14th week of the
semester.
• In each test, test write-up, conduction of experiment, acceptable result, and procedural
knowledge will carry a weightage of 60% and the rest 40% for viva-voce.
• The suitable rubrics can be designed to evaluate each student’s performance and learning
ability. Rubrics suggested in Annexure-II of Regulation book
• The average of 02 tests is scaled down to 20 marks (40% of the maximum marks). The
Sum of scaled-down marks scored in the report write-up/journal and average marks of two
tests is the total CIE marks scored by the student.
Semester End Evaluation (SEE):
• SEE marks for the practical course is 50 Marks.
• SEE shall be conducted jointly by the two examiners of the same institute, examiners are
appointed by the University
• All laboratory experiments are to be included for practical examination.
• (Rubrics) Breakup of marks and the instructions printed on the cover page of the answer
script to be strictly adhered to by the examiners. OR based on the course requirement
evaluation rubrics shall be decided jointly by examiners.
• Students can pick one question (experiment) from the questions lot prepared by the internal
/external examiners jointly.
• Evaluation of test write-up/ conduction procedure and result/viva will be conducted jointly
by examiners.
• General rubrics suggested for SEE are mentioned here, writeup-20%, Conduction
procedure and result in -60%, Viva-voce 20% of maximum marks. SEE for practical shall
www.vtuupdates.com Page 34
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
be evaluated for 100 marks and scored marks shall be scaled down to 50 marks (however,
based on course type, rubrics shall be decided by the examiners)
• Students can pick one experiment from the questions lot of PART A with equal choice to
all the students in a batch.
• PART B: Student should develop a mini project and it should be demonstrated in the
laboratory examination (with report and presentation).
• Weightage of marks for PART A is 60% and for PART B is 40%. General rubrics suggested
to be followed for part A and part B.
• Change of experiment is allowed only once (in part A) and marks allotted to the procedure
part to be made zero.
• The duration of SEE is 03 hours
www.vtuupdates.com Page 35
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
2. What is OpenGL?
OpenGL is the most extensively documented 3D graphics API (Application Pro-gram Interface)
to date. It is used to create Graphics.
3. What is GLUT?
The OpenGL Utility Toolkit (GLUT) is a library of utilities for OpenGL programs, which
primarily perform system-level I/O with the host operating system.
5. What is a Pixel?
In digital imaging, a pixel (or picture element) is a single point in a raster image. The Pixel is the
smallest addressable screen element; it is the smallest unit of picture which can be controlled. Each
Pixel has its address. The address of Pixels corresponds to its coordinate. Pixels are normally
arranged in a 2-dimensional grid, and are often represented using dots or squares.
www.vtuupdates.com Page 36
COMPUTER GRAPHICS AND IMAGE PROCESSING LABORATORY 21CSL66
As far as OpenGL is concerned, there is no camera. More specically, the camera is always located
at the eye space coordinate (0., 0., 0.). To give the appearance of moving the camera, your OpenGL
application must move the scene with the inverse of the camera transformation.
www.vtuupdates.com Page 37