Computer Graphics MCQs with Answers
Practice important Computer Graphics MCQs with answers and explanations.
Chapter: 41
Q1401:
What is the purpose of the glRotatef function in OpenGL?
A. It moves the object
B. It applies a rotation to the object
C. It changes the camera position
D. It scales the object
Correct Answer:
B
Chapter: 41
Q1402:
The matrix stack in OpenGL is useful for:
A. Constructing hierarchical models
B. Performing fast translations
C. Creating lighting effects
D. Rotating objects in 3D space
Correct Answer:
A
Chapter: 41
Q1403:
A camera's up-vector in gluLookAt() specifies:
A. The camera's position
B. The direction in which the camera is looking
C. The direction from the bottom to the top of the viewing volume
D. The angle of rotation of the camera
Correct Answer:
C
Chapter: 41
Q1404:
What does the glLoadIdentity() function do in OpenGL?
A. Translates the camera
B. Resets the current transformation matrix
C. Sets the object's scale
D. Defines the object’s material properties
Correct Answer:
B
Chapter: 41
Q1405:
In a flight simulator, which transformation routine would you use to display the world from the pilot's point of view?
A. glRotatef()
B. pilotView()
C. glTranslatef()
D. glLookAt()
Correct Answer:
B
Chapter: 41
Q1406:
Fill in the blank: The gluLookAt() function is typically used to view a scene from an arbitrary _______.
A. object
B. camera
C. point
D. angle
Correct Answer:
C
Chapter: 41
Q1407:
The glTranslatef() function is used to:
A. Move an object along the x, y, and z axes
B. Rotate an object
C. Scale an object
D. Define the camera view
Correct Answer:
A
Chapter: 41
Q1408:
When using the local coordinate system approach, the correct order of transformations is:
A. Rotate first, then translate
B. Translate first, then rotate
C. Rotate and translate simultaneously
D. No transformation is required
Correct Answer:
B
Chapter: 41
Q1409:
Which OpenGL function is part of the Utility Library and helps with defining the camera's viewpoint?
A. glTranslatef
B. glPushMatrix
C. gluLookAt
D. glRotatef
Correct Answer:
C
Chapter: 41
Q1410:
Fill in the blank: To achieve the effect of rotating the camera around an object in OpenGL, you need to use a combination of glTranslatef() and _______ commands.
A. glPushMatrix
B. glRotatef
C. gluLookAt
D. glPopMatrix
Correct Answer:
B
Chapter: 41
Q1411:
Fill in the blank: The purpose of using polar coordinates in a custom viewing transformation is to define the _______ of the camera's orbit around an object.
A. distance
B. angle
C. elevation
D. position
Correct Answer:
A
Chapter: 41
Q1412:
Which of the following is NOT an OpenGL function related to transformations?
A. glTranslatef
B. glPushMatrix
C. gluLookAt
D. glColor3f
Correct Answer:
D
Chapter: 42
Q1413:
What function is used to rotate an object around a specific axis in OpenGL?
A. glTranslate*()
B. glRotate*()
C. glScale*()
D. gluPerspective()
Correct Answer:
B
Chapter: 42
Q1414:
In the solar system example, which OpenGL function is used to draw a planet?
A. glutWireCube()
B. glutWireSphere()
C. glPushMatrix()
D. gluLookAt()
Correct Answer:
B
Chapter: 42
Q1415:
What does the glPushMatrix() function do in OpenGL?
A. It draws the object
B. It saves the current transformation matrix
C. It pops the transformation matrix
D. It sets the perspective
Correct Answer:
B
Chapter: 42
Q1416:
Which OpenGL function is used to move an object along a specified direction?
A. glRotatef()
B. glTranslatef()
C. glScalef()
D. gluLookAt()
Correct Answer:
B
Chapter: 42
Q1417:
What is the purpose of glRotatef() in the solar system program?
A. To rotate the sun around its axis
B. To rotate the planet around its orbit
C. To scale the planet
D. To translate the planet
Correct Answer:
B
Chapter: 42
Q1418:
When creating a robot arm, what does glTranslatef() do?
A. Moves the local coordinate system to a specific point
B. Rotates the object around a specific axis
C. Scales the object
D. Translates the object relative to the camera view
Correct Answer:
A
Chapter: 42
Q1419:
In the robotic arm program, which transformation function is used to scale a segment of the arm?
A. glRotatef()
B. glTranslatef()
C. glScalef()
D. gluPerspective()
Correct Answer:
C
Chapter: 42
Q1420:
What does the keyboard function in the robot arm program allow you to do?
A. Scale the segments
B. Rotate the segments at the shoulder and elbow
C. Draw new segments
D. Save the current arm state
Correct Answer:
B