More gles fixes
This commit is contained in:
@@ -24,7 +24,7 @@ float trace_cone_ao(sampler3D voxels, const vec3 origin, vec3 dir, const float a
|
||||
sample_pos = dir * dist + origin;
|
||||
float mip = max(log2(diam * voxelgi_resolution), 0.0);
|
||||
float mip_sample = textureLod(voxels, sample_pos * vec3(0.5, 0.5, 0.5) + vec3(0.5, 0.5, 0.5), mip).r;
|
||||
sample_col += (1 - sample_col) * mip_sample;
|
||||
sample_col += (1.0 - sample_col) * mip_sample;
|
||||
dist += max(diam / 2.0, VOXEL_SIZE);
|
||||
diam = dist * aperture;
|
||||
}
|
||||
|
||||
@@ -251,7 +251,7 @@ void main() {
|
||||
envl /= PI;
|
||||
|
||||
vec3 reflection_world = reflect(-v, n);
|
||||
float lod = mip_from_roughness(roughness, envmap_num_mipmaps);
|
||||
float lod = mip_from_roughness(roughness, float(envmap_num_mipmaps));
|
||||
vec3 prefiltered_color = textureLod(senvmap_radiance, envmap_equirect(reflection_world, envmap_data.x), lod).rgb;
|
||||
|
||||
envl.rgb *= albedo;
|
||||
|
||||
Reference in New Issue
Block a user