Cleanup: EEVEE: Rename variable named sample because ...
.. it's a reserved keyword on GL > 4.0.
This commit is contained in:
@@ -245,13 +245,13 @@ void EEVEE_reflection_compute(EEVEE_ViewLayerData *UNUSED(sldata), EEVEE_Data *v
|
||||
EEVEE_downsample_buffer(vedata, txl->color_double_buffer, 9);
|
||||
|
||||
/* Resolve at fullres */
|
||||
int sample = (DRW_state_is_image_render()) ? effects->taa_render_sample :
|
||||
int samp = (DRW_state_is_image_render()) ? effects->taa_render_sample :
|
||||
effects->taa_current_sample;
|
||||
/* Doing a neighbor shift only after a few iteration.
|
||||
* We wait for a prime number of cycles to avoid noise correlation.
|
||||
* This reduces variance faster. */
|
||||
effects->ssr_neighbor_ofs = ((sample / 5) % 8) * 4;
|
||||
switch ((sample / 11) % 4) {
|
||||
effects->ssr_neighbor_ofs = ((samp / 5) % 8) * 4;
|
||||
switch ((samp / 11) % 4) {
|
||||
case 0:
|
||||
effects->ssr_halfres_ofs[0] = 0;
|
||||
effects->ssr_halfres_ofs[1] = 0;
|
||||
|
||||
@@ -177,11 +177,11 @@ vec4 step_blit(void)
|
||||
vec4 step_downsample(void)
|
||||
{
|
||||
#ifdef HIGH_QUALITY /* Anti flicker */
|
||||
vec3 sample = downsample_filter_high(sourceBuffer, uvcoordsvar.xy, sourceBufferTexelSize);
|
||||
vec3 samp = downsample_filter_high(sourceBuffer, uvcoordsvar.xy, sourceBufferTexelSize);
|
||||
#else
|
||||
vec3 sample = downsample_filter(sourceBuffer, uvcoordsvar.xy, sourceBufferTexelSize);
|
||||
vec3 samp = downsample_filter(sourceBuffer, uvcoordsvar.xy, sourceBufferTexelSize);
|
||||
#endif
|
||||
return vec4(sample, 1.0);
|
||||
return vec4(samp, 1.0);
|
||||
}
|
||||
|
||||
vec4 step_upsample(void)
|
||||
|
||||
@@ -108,8 +108,8 @@ void main()
|
||||
|
||||
weight = texel_solid_angle(facecoord, halfpix);
|
||||
|
||||
vec4 sample = textureLod(probeHdr, cubevec, lodMax);
|
||||
sh += sample.rgb * coef * weight;
|
||||
vec4 samp = textureLod(probeHdr, cubevec, lodMax);
|
||||
sh += samp.rgb * coef * weight;
|
||||
weight_accum += weight;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -80,9 +80,9 @@ void main()
|
||||
vec2 accum = vec2(0.0);
|
||||
|
||||
for (float i = 0; i < sampleCount; i++) {
|
||||
vec3 sample = sample_cone(i, invSampleCount, M_PI_2 * visibilityBlur, cos, T, B);
|
||||
float depth = texture(probeDepth, sample).r;
|
||||
depth = get_world_distance(depth, sample);
|
||||
vec3 samp = sample_cone(i, invSampleCount, M_PI_2 * visibilityBlur, cos, T, B);
|
||||
float depth = texture(probeDepth, samp).r;
|
||||
depth = get_world_distance(depth, samp);
|
||||
accum += vec2(depth, depth * depth);
|
||||
}
|
||||
|
||||
|
||||
@@ -209,9 +209,9 @@ vec3 probe_evaluate_planar(int id, PlanarData pd, vec3 P, vec3 N, vec3 V, float
|
||||
/* TODO: If we support non-ssr planar reflection, we should blur them with gaussian
|
||||
* and chose the right mip depending on the cone footprint after projection */
|
||||
/* NOTE: X is inverted here to compensate inverted drawing. */
|
||||
vec3 sample = textureLod(probePlanars, vec3(refco.xy * vec2(-0.5, 0.5) + 0.5, id), 0.0).rgb;
|
||||
vec3 radiance = textureLod(probePlanars, vec3(refco.xy * vec2(-0.5, 0.5) + 0.5, id), 0.0).rgb;
|
||||
|
||||
return sample;
|
||||
return radiance;
|
||||
}
|
||||
|
||||
void fallback_cubemap(vec3 N,
|
||||
|
||||
Reference in New Issue
Block a user