Thread: Eliminating lighting "over-bright"

  1. #1
    The Right Honourable psychopath's Avatar
    Join Date
    Mar 2004
    Location
    Where circles begin.
    Posts
    1,071

    Eliminating lighting "over-bright"

    I'm still working on perfecting my engines lighting system(s), and I have one more issue to fix before moving on to implement an optional deferred shading system.

    To render the scene with GLSL lighting, I render an initial Z-pass, and then render the scene for each visible light, executing the lighting shader for each light. The problem though, is that when more than one light is visible at a time, some walls and objects receive too much light, even if the lights and objects are nowhere near each other.

    What I need to know, is if there is any way to restrict the lighting stay within a certain radius. I already use lighting attenuation, which seems to attenuate lighting on floors and ceilings fine, but walls and other objects that receive more direct light still get too bright.

    I tried scissor testing, but that didn't work out too well, and when scissor rectangles overlapped, the problem was still visible.

    Thanks.
    M.Eng Computer Engineering Candidate
    B.Sc Computer Science

    Robotics and graphics enthusiast.

  2. #2
    vae victus! skorman00's Avatar
    Join Date
    Nov 2003
    Posts
    594
    Tweak that attenuation value...and by tweak I mean go really high, go really low, then find a sweet spot in the middle =)

    This might be completely irrelavent to your problem, but you may want to check out this link: http://www.lighthouse3d.com/opengl/g...php?pointlight

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. GLSL lighting (again)
    By psychopath in forum Game Programming
    Replies: 6
    Last Post: 12-19-2005, 01:34 PM
  2. Replies: 6
    Last Post: 11-12-2005, 11:57 AM
  3. My attempt at lighting math
    By psychopath in forum Game Programming
    Replies: 11
    Last Post: 03-30-2005, 12:35 AM
  4. Lighting a Direct3D 9 mesh sphere
    By bennyandthejets in forum Game Programming
    Replies: 12
    Last Post: 02-14-2005, 01:19 AM
  5. need help with opengl lighting!!
    By genghis37 in forum Game Programming
    Replies: 1
    Last Post: 06-22-2002, 12:28 AM