Results 1 to 3 of 3

Thread: lighting questions / strategies

  1. #1
    Junior Member Newbie andreasw's Avatar
    Join Date
    Oct 2008
    Location
    Írebro, Sweden
    Posts
    2

    lighting questions / strategies

    Hi,

    new to opengl and was thinking about the lighting. With the limit of for example 8 gl lights, what are the "best practices" when dealing with big overview scenes for example new york city from above. with alot of light sources.

    do you just fake it with changing textures around the light sources, and as you move in closer, make only the lights closest to the viewport become real opengl lights?

    Or do you roll your own light entirely from scratch?

    Thanks in advance

  2. #2
    Super Moderator OpenGL Lord
    Join Date
    Dec 2003
    Location
    Grenoble - France
    Posts
    5,574

    Re: lighting questions / strategies

    As you understood, basic opengl hardware lighting does not scale well with the number of lights.
    Typically games udes precomputed lighting for the whole static scene, applied as texture mapping. For dynamic objects, only the nearest n lights are taken in account (each object can have its own lights).

    Other way of doing is is defered shading approach : need more modern hardware, it has quite an important fixed cost, but scales well with the number of lights.
    Look at this this thread for interesting info and demo+code :
    http://www.opengl.org/discussion_boa...&Number=232157

  3. #3
    Junior Member Newbie andreasw's Avatar
    Join Date
    Oct 2008
    Location
    Írebro, Sweden
    Posts
    2

    Re: lighting questions / strategies

    Hi,

    thank you for the prompt reply! I have read up on these various aspects, but i think they were abit over my head for now.

    Are there any thoughts on precompiled lighting when dealing with an environment that is changing alot, for example back to new york - cars moving along the roads, boats in the harbor and this reflecting on the buildings, streets and other objects.

    I guess rolling our own lighting sounds like the only realistic approach for keeping lighting "under control" at this point.

Similar Threads

  1. Questions about Lighting and Shadowing
    By tomcio in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 04-16-2011, 06:28 AM
  2. Some questions on deferred lighting.
    By Sanctus in forum OpenGL: GLSL
    Replies: 5
    Last Post: 09-08-2009, 09:33 AM
  3. Questions in Inferred Lighting
    By LangFox in forum OpenGL: Advanced Coding
    Replies: 0
    Last Post: 08-20-2009, 09:26 PM
  4. Lighting questions and problems
    By juanmanuelsanchez in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 02-11-2007, 08:11 PM
  5. Some lighting questions!
    By Oliver LS in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 03-23-2002, 08:49 PM

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