force going all the way down when subsampling grates
This commit is contained in:
parent
fd6d38c979
commit
d14718daef
|
|
@ -758,6 +758,7 @@ int LightContributionToSample( trace_t *trace )
|
|||
light = trace->light;
|
||||
|
||||
/* clear color */
|
||||
trace->forceSubsampling = qfalse; /* to make sure */
|
||||
VectorClear( trace->color );
|
||||
VectorClear( trace->colorNoShadow );
|
||||
VectorClear( trace->directionContribution );
|
||||
|
|
|
|||
|
|
@ -1781,7 +1781,6 @@ sets up certain trace values
|
|||
|
||||
float SetupTrace( trace_t *trace )
|
||||
{
|
||||
trace->forceSubsampling = qfalse;
|
||||
VectorSubtract( trace->end, trace->origin, trace->displacement );
|
||||
trace->distance = VectorNormalize( trace->displacement, trace->direction );
|
||||
VectorCopy( trace->origin, trace->hit );
|
||||
|
|
|
|||
|
|
@ -1817,6 +1817,13 @@ static void SubsampleRawLuxel_r( rawLightmap_t *lm, trace_t *trace, vec3_t sampl
|
|||
/* sample light */
|
||||
|
||||
LightContributionToSample( trace );
|
||||
if(trace.forceSubsampling)
|
||||
{
|
||||
/* alphashadow: we subsample as deep as we can */
|
||||
++lighted;
|
||||
++mapped;
|
||||
++mapped;
|
||||
}
|
||||
|
||||
/* add to totals (fixme: make contrast function) */
|
||||
VectorCopy( trace->color, luxel[ b ] );
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user