Skip to main content

Computer Graphics MCQs with Answers

Practice important Computer Graphics MCQs with answers and explanations.

Chapter: 42
Q1421:
How do you add additional segments to a robotic arm in OpenGL?
A. By using glPushMatrix() and glPopMatrix() to save and restore transformations
B. By adding new glTranslatef() commands
C. By modifying gluLookAt() parameters
D. By changing the glutDisplayFunc()
Correct Answer: A
Chapter: 42
Q1422:
What is the purpose of glPopMatrix() in the robotic arm example?
A. It saves the current transformation state
B. It restores the saved transformation state
C. It scales the arm segment
D. It translates the segment
Correct Answer: B
Chapter: 42
Q1423:
The robot arm program uses glRotatef() to rotate segments around their respective joints. Which joints are being rotated in the example?
A. Shoulder and wrist
B. Shoulder and elbow
C. Elbow and wrist
D. Wrist and fingers
Correct Answer: B
Chapter: 42
Q1424:
In OpenGL, gluPerspective() is used for which purpose in the solar system program?
A. To scale the objects
B. To set the viewing perspective
C. To translate the camera position
D. To rotate the objects
Correct Answer: B
Chapter: 42
Q1425:
What happens when the y key is pressed in the robot arm program?
A. The elbow rotates clockwise
B. The shoulder rotates counterclockwise
C. The year changes in the solar system simulation
D. The shoulder rotates clockwise
Correct Answer: D
Chapter: 42
Q1426:
Fill in the blank: In OpenGL, to rotate an object around its local axis, we use the function ______.
A. glTranslatef()
B. glRotatef()
C. gluPerspective()
D. glScalef()
Correct Answer: B
Chapter: 42
Q1427:
The moon can be added to the planet in the solar system program by using additional ________ functions.
A. glPushMatrix() and glPopMatrix()
B. glRotatef() and glTranslatef()
C. glScalef() and gluPerspective()
D. glutWireSphere() and glTranslatef()
Correct Answer: A
Chapter: 42
Q1428:
Which OpenGL function is used to change the viewpoint in the solar system program?
A. gluLookAt()
B. glTranslatef()
C. glRotatef()
D. glPushMatrix()
Correct Answer: A
Chapter: 42
Q1429:
The solar system program uses _______ to simulate the passage of time for both the planet’s rotation and revolution.
A. glRotatef()
B. glPushMatrix()
C. glTranslatef()
D. gluPerspective()
Correct Answer: A
Chapter: 42
Q1430:
Fill in the blank: The function used to adjust the scaling of an object in OpenGL is ________.
A. glTranslatef()
B. glRotatef()
C. glScalef()
D. gluLookAt()
Correct Answer: C
Chapter: 43
Q1431:
What is the role of NORMAL vectors in OpenGL lighting?
A. Determine the color of the light
B. Determine the orientation of an object relative to light sources
C. Define the material properties of the object
D. Control the intensity of the light
Correct Answer: B
Chapter: 43
Q1432:
OpenGL lighting is based on which color model?
A. RGB
B. CMYK
C. HSL
D. YUV
Correct Answer: A
Chapter: 43
Q1433:
What does ambient light represent in OpenGL lighting?
A. Light coming from a particular light source
B. Light that is scattered throughout the scene
C. Light that comes from a single direction
D. Light that is absorbed by surfaces
Correct Answer: B
Chapter: 43
Q1434:
What happens when a light source is turned off in OpenGL?
A. Ambient light is also turned off
B. All light in the scene disappears
C. Bounced light disappears
D. The scene becomes completely dark
Correct Answer: C
Chapter: 43
Q1435:
Which of the following is not a lighting component in OpenGL?
A. Emissive
B. Diffuse
C. Specular
D. Transparency
Correct Answer: D
Chapter: 43
Q1436:
Which function is used to initialize a material's shininess in OpenGL?
A. glLightfv
B. glMaterialfv
C. glShadeModel
D. glEnable
Correct Answer: B
Chapter: 43
Q1437:
What is the default color for light in OpenGL's GL_LIGHT0?
A. Red
B. Green
C. Blue
D. White
Correct Answer: D
Chapter: 43
Q1438:
OpenGL can support how many different light sources in a scene by default?
A. 4
B. 6
C. 8
D. 10
Correct Answer: C
Chapter: 43
Q1439:
What does the glClearColor() function do in OpenGL?
A. Sets the color of the material
B. Clears the color buffer with a specified color
C. Defines the position of the light source
D. Enables lighting calculations
Correct Answer: B
Chapter: 43
Q1440:
What OpenGL function is used to enable lighting?
A. glEnable(GL_LIGHTING)
B. glMaterialfv(GL_FRONT, GL_SPECULAR)
C. glLightfv(GL_LIGHT0, GL_POSITION)
D. glShadeModel(GL_SMOOTH)
Correct Answer: A

Test Your Knowledge

Take a timed quiz on Computer Graphics

🚀 Start Quiz Now