Part of the Khronos Group

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 2 of 2

Thread: What is the 3rd "vector" in the arguments of LookAt?

  1. #1
    Junior Member Newbie winterheat's Avatar
    Join Date
    May 2012

    What is the 3rd "vector" in the arguments of LookAt?

    I wonder what is the 3rd vector (the 3rd row) in the following code?

    Code :
            gluLookAt( -512, -384, 700,
                      512, 384, 0,
                      0.0f, 1.0f, 0.0f);

    It is strange that if the first row is 512, 384, (the camera's location), then I see the target as if I am standing with my eyes right on top of the desk's surface, but if I change it to -512, -384, that means I walked away to the lower left side of the desk and look down the floor?... or look at the desk? I thought the 3rd row tells how the camera is facing... so if I walk away from the desk and still face the same orientation, I should see the floor. So what is the third row anyway and how does it work?

  2. #2
    Member Regular Contributor
    Join Date
    Jan 2012
    Please avoid doubleposts, i answered your other posting.

Tags for this Thread

Posting Permissions

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