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: Light Positioning

  1. #1
    Member Regular Contributor
    Join Date
    Nov 2000
    Location
    Sydney, NSW, Australia
    Posts
    428

    Light Positioning

    In my flight simulator i use gluLookAt to change my view, but the Light position changes with the gluLookAt transformations, so when i move the light source also moves, how can i correct this so the light source stays constant relative to the ground and not to the camera??
    :: Sleep is a poor substitute for caffeine ::

  2. #2
    Senior Member OpenGL Guru
    Join Date
    Mar 2001
    Posts
    3,768

    Re: Light Positioning

    Create the lightsource after you call gluLookAt. The lightsource is transformed by the MODELVIEW matrix stack.

Posting Permissions

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