CSE3313 - Computer Graphics
homework exercises

CSE3313
Computer Graphics

Robot Arm Question


This question is from the 2004 CSE3313 exam. See if you can write an OpenGL program that solves the problem.


Consider the diagram below, which shows a simple robot arm simulation. The robot consists of three arm components, S1, S2, and S3 which are connected together and allowed to rotate with limited degrees of freedom as shown in the diagram.

Write a C function drawRobotArm that draws the robot in its current state using OpenGL. The function should take the following parameters: phi1, phi2, phi3, phi4. These are the angles in degrees as shown in the diagram, representing the current angles to use when drawing the robot. The function should use OpenGL transformations to draw the robot in the correct position according to the parameters passed.

You can assume the following:


This material is part of the CSE3313 Computer Graphics course.
Copyright © Jon McCormack, 2005.  All rights reserved.

Last Modified: April 27, 2005