Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 2 of 2

Thread: How can avoid the center point problem in Zooming as well as in Rotation..?

  1. #1
    Junior Member Newbie
    Join Date
    Jan 2002
    Posts
    27

    How can avoid the center point problem in Zooming as well as in Rotation..?

    Hi,

    I displyed a 3D object in a MFC window.I try to zoom and rotate that object.I use gluLookat()for zooming,glRotate() for rotation.in the gluLookAt() i give the center point x,y and z as constant value 0.
    I incremented the viewPointZ variable only for zoom operation.

    gluLookAt(0,0,viewPointZ, 0,0, 0,0, 1.0, 0);

    Then i am zoom in/out the object using the arrow keys then, object is zooming but it zooming is based on the center point so it comes toward the monitor is right/left aligned to the window. Is any problem of center point,eye point or up vector ?

    pls notify where the mistake to me ?

    Thanx,
    Jerry

  2. #2
    Senior Member OpenGL Guru
    Join Date
    Jul 2000
    Location
    S41.16.25 E173.16.21
    Posts
    2,407

    Re: How can avoid the center point problem in Zooming as well as in Rotation..?

    i didnt really understand the text of the question but normally when u 'zoom' u use a smaller fov eg gluPerspective( fov, aspect, near, far )
    what u are doing is not 'zooming' but 'moving' the camera/viewpoint

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •