Go away, I don't want to read about OpenGL. Later dudes.

/ScarT


2009/2/28 Julian Moschüring <ar...@gmx.com>

> Ouh, you render a light map and than the textures with dynamic lights?
> Multiplying the light map with the dynamic light geometry will not add
> the light as intended.
>
> An easy solution would be:
>
> glBlendEquation( GL_FUNC_ADD );
> glDisable( GL_FOG );
> DrawLightmaps( );
>
> glBlendFunc( GL_ONE, GL_ONE );
> DrawDynamicLightmaps( );
>
> glBlendFunc( GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA );
> glEnable( GL_FOG );
> glBlendFunc( GL_DST_COLOR, GL_ZERO );
> DrawCompletelyUnlitGeometry( );
>
>
> This is doing the following in 3 passes:
> 1. Render the lightmap
> 2. Add the dynamic lightning to the lightmap
> 3. Add textures and fog values
>
> But you can use dynamic lightning and static lightmaps in one pass
> without problems. You should read a book about opengl...
>
> Andrew Lucas schrieb:
> > Nah, it doesn't want to work. The unlit triangles not only become much
> darker, but the fog affects all of them incorrectly. I guess it's not that
> important anyway, I could just render the dynlights after everything else
> has been rendered, except that they won't be able to light up completely
> dark areas.
> >
> >
> >
> > Thanks for your help though.
> >
> > _________________________________________________________________
> > Invite your mail contacts to join your friends list with Windows Live
> Spaces. It's easy!
> >
> http://spaces.live.com/spacesapi.aspx?wx_action=create&wx_url=/friends.aspx&mkt=en-us
> > _______________________________________________
> > To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> > http://list.valvesoftware.com/mailman/listinfo/hlcoders
> >
>
>
> _______________________________________________
> To unsubscribe, edit your list preferences, or view the list archives,
> please visit:
> http://list.valvesoftware.com/mailman/listinfo/hlcoders
>
>
_______________________________________________
To unsubscribe, edit your list preferences, or view the list archives, please 
visit:
http://list.valvesoftware.com/mailman/listinfo/hlcoders

Reply via email to