Erik Hofman wrote:
> Frederic Bouvier wrote:
>
> >>This shouldn't be happening.
> >>Could you confirm that after a make clean; make install in the
> >>SimGear/simgear/scene/sky directory and remaking fgfs the problem still
> >>exists?
> >
> >
> > I confirm. And the patch below solve the problem.
> >
> > --- main.cxx    31 Jul 2003 14:47:56 -0000      1.117
> > +++ main.cxx    14 Aug 2003 21:32:35 -0000
> > @@ -736,6 +736,9 @@
> >
> >              // return to the desired diffuse color
> >              ssgGetLight( 0 ) -> setColour( GL_DIFFUSE,
l->scene_diffuse );
> > +
> > +            // return to normal fog density
> > +            glFogf ( GL_FOG_DENSITY, fog_exp2_density );
>
> I'm not sure this is the right solution because it overrides the fog
> settings which where just defined in the thesky->preDraw() function.
>
> It starts to look like a problem with the OpenGL driver as Curtis
> mentioned this to me privately:
>
> > Ok, it seems from my opengl book that if you glPushAttrib(GL_FOG_BIT)
> > first then set GL_FOG_DENSITY, then the glPopAttrib() should restore
> > the density to the original value ...
> >
> > Maybe windows doesn't perfectly implement this???
>
> Which video hardware are you using?

I am using a NVIDIA GF3 Ti200.

>From my understanding of the current code, you modify the fog density for
the sun punch through in a function call at line main.cxx:735
( 'thesky->preDraw();' ) and then line main.cxx:751 we draw the scene.
And there is no glFogf( GL_FOG_DENSITY, something ) in between, so the
scene ( terrain ) is drawn with the last density set, that is the sun punch
through.

Am I missing something ? I ran the program under debugger with breakpoint
on every glFogf( GL_FOG_DENSITY,...) I found and there is no
call to glFogf between thesky->preDraw() and
ssgCullAndDraw( globals->get_scenery()->get_scene_graph() )

-Fred



_______________________________________________
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel

Reply via email to