Results 1 to 3 of 3

Thread: constant lighting position

  1. #1

    constant lighting position

    Hi guys,
    i have a problem with light in my program that lets you move around in a 3d enviroment: when i move the camera, the lighting on the objects changes, as if the light source would be moving around with the camera.. how can i fix that (so it gives the impression that there is a light at a constant position shining in a certain direction)

  2. #2
    Senior Member Regular Contributor
    Join Date
    Oct 2001
    Princeton, NJ

    Re: constant lighting position

    Set the light position after you modify the modelview matrix.

  3. #3

    Re: constant lighting position

    Jep, works great. Just what i needed. Thanks alot there

Similar Threads

  1. Get Pixel Position for lighting and ssao from depth ?
    By RobertBerg in forum OpenGL: Basic Coding
    Replies: 5
    Last Post: 04-15-2015, 06:35 PM
  2. Replies: 2
    Last Post: 10-16-2012, 11:23 AM
  3. FAQ - Fixed function lighting position problems
    By Zenja in forum OpenGL: Advanced Coding
    Replies: 12
    Last Post: 01-03-2011, 08:16 AM
  4. Diffuse Lighting Position Problem (long)
    By miw954 in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 09-02-2009, 10:41 AM
  5. Problem: Inverted lighting position
    By Kalle in forum OpenGL: Basic Coding
    Replies: 3
    Last Post: 08-05-2008, 01:22 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Proudly hosted by Digital Ocean