diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/tnl/t_vb_fog.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/tnl/t_vb_fog.c b/src/mesa/tnl/t_vb_fog.c index ddf849a658e..f1d01bc47f9 100644 --- a/src/mesa/tnl/t_vb_fog.c +++ b/src/mesa/tnl/t_vb_fog.c @@ -1,8 +1,8 @@ /* * Mesa 3-D graphics library - * Version: 6.1 + * Version: 6.5 * - * Copyright (C) 1999-2004 Brian Paul All Rights Reserved. + * Copyright (C) 1999-2005 Brian Paul All Rights Reserved. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -197,6 +197,12 @@ run_fog_stage(GLcontext *ctx, struct tnl_pipeline_stage *stage) else { /* use glFogCoord() coordinates */ input = VB->FogCoordPtr; /* source data */ + + /* input->count may be one if glFogCoord was only called once + * before glBegin. But we need to compute fog for all vertices. + */ + input->count = VB->ObjPtr->count; + VB->FogCoordPtr = &store->fogcoord; /* dest data */ } |