opengl, Computer Graphics

Assignment Help:
Write a program that allows interactive manipulation of the position and orientation of a camera.
Draw a teapot at the global origin 0,0,0.
You can find a shaded teapot model and source code teapot_glut.c.

Initially, the camera is at 0,0,10 looking down the -z axis (looking at the origin 0,0,0).



The main objective of this homework is to manipulate the position and orientation of the camera. The position of the camera is restricted to be on the surface of a virtual sphere with the radius of 10. So you can imagine a teapot at the origin, and a camera on a surrounding sphere pointing at the teapot.

There are two camera manipulation instruction, elevation and swing. In elevation mode, the camera should be elevated on the surface of the sphere while maintaining the look-at point at the origin. The range of elevation on the surface of a sphere is between -90 and 90 degree. Use mouse motion function to implement the user interaction. Users should be able to elevate the camera by dragging mouse upward.

In swing mode, the camera should be moved sideways on the surface of the sphere while maintaining the look-at point at the origin. Use mouse motion function to implement the user interaction. Users should be able to swing the camera by dragging mouse sideways. Note that during the swing operation, the elevation level should be preserved and the camera should not tilt sideways.

Using a pull-down menu, a user should be able to toggle between grid view on and off.
Quit menu will terminate the program.

Related Discussions:- opengl

Polygon -rendering methods, Polygon -Rendering Methods Now we will see...

Polygon -Rendering Methods Now we will see the application of an illumination model to execute the rendering of standard graphics objects that are formed along with polygonal

Advantage and disadvantage of plasma panel-graphics hardware, Advantage and...

Advantage and Disadvantage of Plasma panel - Graphics Hardware Advantage 1. Slim design as Wall mountable 2. Larger than LCD screens Disadvantage

Oblique projection, find the transformation and draw the cube for cavalier...

find the transformation and draw the cube for cavalier and cabinet with theta = 37 degree

Assumption for digital differential analyzer algorithm, Assumption regardin...

Assumption regarding to the Digital Differential Analyzer Algorithm The line generation by DDA is discussed merely for the first Quadrant, whether the line lies in the other q

Printing press discovered in 16th century, Printing Press discovered in 16t...

Printing Press discovered in 16th century: Books provided more role models & multiple perspectives. Exposure to books demanded that learners employ critical thinking to r

What is a model sheet?, Question 1 Briefly explain the twelve principles o...

Question 1 Briefly explain the twelve principles of animation Question 2 Explain the methods to set-up pre and post-infinity curves Question 3 What is a model sheet? Exp

Cohen sutherland algorithm - 2d clipping algorithms, Cohen Sutherland algor...

Cohen Sutherland algorithm Point clipping is very simple.  All you need to check is whether a point is inside the window extremes in x- and y-directions.  For line clipping sev

Containment test - visible surface detection, Containment Test -  visible s...

Containment Test -  visible surface detection Test: That is Containment test: it can be either comprised (contained) or surrounding polygon, if intersection test fails. The

Curve segment - properties of bezier curves, Curve segment - properties of ...

Curve segment - properties of bezier curves Note : 1) The joining point on the curve along w.r.t. the parameter based upon second derivates of Q(t) is the acceleration. Wh

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd