PDA

View Full Version : Pan functionality



AeroSujan
11-02-2009, 04:46 AM
Dear Friends
Please give me some idea how can i give pan functionality on the items in the view.

I am trying with
///////////////////////////////////////////////////////////
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glTranslated(dx,dy,0.0f);
glCallList(object);
////////////////////////////////////////////////////////////////
// But this is not panning/translating my objects.
any help would be appreciated !

km,
11-02-2009, 12:48 PM
What are the values in dx, dy? Is it significant then you may expect to see something.

Also, you are over-writing existing Model view matrix. So I am assuming your glCallList is drawing objects at OpenGL's default position. If you expect to have some other model_view matrix and not identity then take care of it.