Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

OpenGL max Light limit

horiahoria Member Posts: 32
I wish to make a game engine and I noticed that other advanced game engines(Quake III, Unreal Tournament etc.) and graphics app(3DS Max,Maya etc.) had more than 8 sources of light.
I wish to know how they did that and, possibly, how I colud do that.

I thank you in advance!


Comments

  • gautamgautam Member Posts: 642
    Minimum of 8 lights are supported. More depends on hardware. You can get the number of lights supported by using

    [code]
    glGetIntegerv(GL_MAX_LIGHTS, param);
    [/code]

    If I remember correctly Quake used their own method of lighting.


    : I wish to make a game engine and I noticed that other advanced game engines(Quake III, Unreal Tournament etc.) and graphics app(3DS Max,Maya etc.) had more than 8 sources of light.
    : I wish to know how they did that and, possibly, how I colud do that.
    :
    : I thank you in advance!
    :
    :
    :

  • SephirothSephiroth Fayetteville, NC, USAMember Posts: 1,035
    DO NOT USE GL LIGHTING FOR EFFECTS IN A GAME!!!!!

    You should go check the OpenGL FAQ at OpenGL.org about why. They ***KILL*** frames. What normal game-engines use GL lights for are things that are VERY sparse so they won't kill frames. There is another method of lighting that looks almost as good and is what the big dogs use called TnL. All half-decent video-cards have it supproted, and it's much faster then GL lighting. GL lights should only be used in 3D editors or extremely sparsely in game-engines unless you only want a very few people to be able to play it.

    -[italic][b][red]S[/red][purple]e[/purple][blue]p[/blue][green]h[/green][red]i[/red][purple]r[/purple][blue]o[/blue][green]t[/green][red]h[/red][/b][/italic]

  • horiahoria Member Posts: 32
    Thank you a lot!

    Now that I know this I can focus on this TnL (wich I suppose comes from Transforming and Lighting).
    Could you tell me where I can find some material on this subject. I will ofcourse try to find out more about it but I need all the help I can get.
  • SephirothSephiroth Fayetteville, NC, USAMember Posts: 1,035
    : Thank you a lot!
    :
    : Now that I know this I can focus on this TnL (wich I suppose comes from Transforming and Lighting).
    : Could you tell me where I can find some material on this subject. I will ofcourse try to find out more about it but I need all the help I can get.
    :
    nVidia.com has a demo with sources on this, and I think it can do up to like 4000 lights in the demo alone. It's a pretty demo since the lights are colored.

    -[italic][b][red]S[/red][purple]e[/purple][blue]p[/blue][green]h[/green][red]i[/red][purple]r[/purple][blue]o[/blue][green]t[/green][red]h[/red][/b][/italic]

Sign In or Register to comment.