PDA

View Full Version : Zoom and pan features with the help of mouse



Scorpio
01-31-2011, 06:26 PM
Hi ,
I need your help guys !!
I have created the model.

I want to zoom in and out with the help of mouse center scroller rotation. Also I want to pan the model with the help of clicking in the model.
Can some one give me some solve template of how to perform this.
or any sample code.
Any help will be appreciated caus its very urgent.

marshats
01-31-2011, 09:25 PM
If you are using GLUT take a look at gltzpr (http://www.nigels.com/glt/gltzpr/).

Scorpio
02-01-2011, 12:27 AM
Is there any other way of achieving the desire results.

Scorpio
02-01-2011, 12:41 AM
I need to use keyboard and mouse functions (callback functions) to zoom and pan camera (the camera function that has been provided needs to be modified). This is the requirement for completing the project.

Alfonse Reinheart
02-01-2011, 12:49 AM
Is there any other way of achieving the desire results.

You mean a way other than downloading a library that does exactly what you need?

Yes. You could just write it yourself. The documentation for GLUT/FreeGLUT explains how to get mouse input.


This is the requirement for completing the project.

This sounds suspiciously like homework. In which case you should already know everything you need to make it work.

D3GAN
02-01-2011, 01:18 PM
hi
for clicking(picking) problem this is very good tutorial

http://gpwiki.org/index.php/OpenGL:Tutorials:Picking

Scorpio
02-02-2011, 01:32 AM
Yeah every one comes to openGl for either of these three things:
1) Project or office work
2) Homework
3) Research Work

The irony is that no one teaches anything these days every thing we need to learn by our own. But OpenGL forum is really helpful for people like me!!