diff options
author | Brecht Van Lommel <brecht@blender.org> | 2022-08-03 20:27:23 +0300 |
---|---|---|
committer | Brecht Van Lommel <brecht@blender.org> | 2022-08-03 20:28:05 +0300 |
commit | cc12f3e0ba11b108edcefd45e0ccdf02b2a672f4 (patch) | |
tree | bae1fb8bc978a25d5f490418cc8b2d58b780356c /source/blender/draw/engines/eevee_next/shaders | |
parent | 81d75affb18bad6734e4c8baa0d735bfec0dcc6e (diff) |
Cleanup: fix various typos
Contributed by luzpaz.
Differential Revision: https://developer.blender.org/D15588
Diffstat (limited to 'source/blender/draw/engines/eevee_next/shaders')
5 files changed, 13 insertions, 13 deletions
diff --git a/source/blender/draw/engines/eevee_next/shaders/eevee_film_lib.glsl b/source/blender/draw/engines/eevee_next/shaders/eevee_film_lib.glsl index 135507d956c..08027f2ef6c 100644 --- a/source/blender/draw/engines/eevee_next/shaders/eevee_film_lib.glsl +++ b/source/blender/draw/engines/eevee_next/shaders/eevee_film_lib.glsl @@ -254,7 +254,7 @@ void film_get_catmull_rom_weights(vec2 t, out vec2 weights[4]) weights[3] = fct3 - fct2; } -/* Load color using a special filter to avoid loosing detail. +/* Load color using a special filter to avoid losing detail. * \a texel is sample position with subpixel accuracy. */ vec4 film_sample_catmull_rom(sampler2D color_tx, vec2 input_texel) { @@ -390,7 +390,7 @@ vec4 film_amend_combined_history( float t = line_aabb_clipping_dist(color_history.rgb, clip_dir.rgb, min_color.rgb, max_color.rgb); color_history.rgb += clip_dir.rgb * saturate(t); - /* Clip alpha on its own to avoid interference with other chanels. */ + /* Clip alpha on its own to avoid interference with other channels. */ float t_a = film_aabb_clipping_dist_alpha(color_history.a, clip_dir.a, min_color.a, max_color.a); color_history.a += clip_dir.a * saturate(t_a); @@ -406,16 +406,16 @@ float film_history_blend_factor(float velocity, { /* 5% of incoming color by default. */ float blend = 0.05; - /* Blend less history if the pixel has substential velocity. */ + /* Blend less history if the pixel has substantial velocity. */ blend = mix(blend, 0.20, saturate(velocity * 0.02)); /** * "High Quality Temporal Supersampling" by Brian Karis at Siggraph 2014 (Slide 43) - * Bias towards history if incomming pixel is near clamping. Reduces flicker. + * Bias towards history if incoming pixel is near clamping. Reduces flicker. */ float distance_to_luma_clip = min_v2(vec2(luma_history - luma_min, luma_max - luma_history)); /* Divide by bbox size to get a factor. 2 factor to compensate the line above. */ distance_to_luma_clip *= 2.0 * safe_rcp(luma_max - luma_min); - /* Linearly blend when history gets bellow to 25% of the bbox size. */ + /* Linearly blend when history gets below to 25% of the bbox size. */ blend *= saturate(distance_to_luma_clip * 4.0 + 0.1); /* Discard out of view history. */ if (any(lessThan(texel, vec2(0))) || any(greaterThanEqual(texel, film_buf.extent))) { @@ -451,13 +451,13 @@ void film_store_combined( float velocity = length(motion); - /* Load weight if it is not uniform accross the whole buffer (i.e: upsampling, panoramic). */ + /* Load weight if it is not uniform across the whole buffer (i.e: upsampling, panoramic). */ // dst.weight = film_weight_load(texel_combined); color_dst = film_sample_catmull_rom(in_combined_tx, history_texel); color_dst.rgb = film_YCoCg_from_scene_linear(color_dst.rgb); - /* Get local color bounding box of source neighboorhood. */ + /* Get local color bounding box of source neighborhood. */ vec4 min_color, max_color; film_combined_neighbor_boundbox(src_texel, min_color, max_color); @@ -622,7 +622,7 @@ void film_process_data(ivec2 texel_film, out vec4 out_color, out float out_depth src = film_sample_get(i, texel_film); film_sample_accum_combined(src, combined_accum, weight_accum); } - /* NOTE: src.texel is center texel in incomming data buffer. */ + /* NOTE: src.texel is center texel in incoming data buffer. */ film_store_combined(dst, src.texel, combined_accum, weight_accum, out_color); } diff --git a/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_dilate_comp.glsl b/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_dilate_comp.glsl index c59b7d7f4df..99186ab6f67 100644 --- a/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_dilate_comp.glsl +++ b/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_dilate_comp.glsl @@ -1,7 +1,7 @@ /** * Dilate motion vector tiles until we covered maximum velocity. - * Outputs the largest intersecting motion vector in the neighboorhod. + * Outputs the largest intersecting motion vector in the neighborhood. * */ @@ -62,7 +62,7 @@ bool is_inside_motion_line(ivec2 tile, MotionLine motion_line) /* NOTE: Everything in is tile unit. */ float dist = point_line_projection_dist(vec2(tile), motion_line.origin, motion_line.normal); /* In order to be conservative and for simplicity, we use the tiles bounding circles. - * Consider that both the tile and the line have bouding radius of M_SQRT1_2. */ + * Consider that both the tile and the line have bounding radius of M_SQRT1_2. */ return abs(dist) < M_SQRT2; } diff --git a/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_gather_comp.glsl b/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_gather_comp.glsl index a7329f77181..5249e6637b6 100644 --- a/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_gather_comp.glsl +++ b/source/blender/draw/engines/eevee_next/shaders/eevee_motion_blur_gather_comp.glsl @@ -22,7 +22,7 @@ const int gather_sample_count = 8; * target post-fx framebuffer. */ vec4 motion_blur_sample_velocity(sampler2D velocity_tx, vec2 uv) { - /* We can load velocity without velocity_resolve() since we resovled during the flatten pass. */ + /* We can load velocity without velocity_resolve() since we resolved during the flatten pass. */ vec4 velocity = velocity_unpack(texture(velocity_tx, uv)); return velocity * vec2(textureSize(velocity_tx, 0)).xyxy * motion_blur_buf.motion_scale.xxyy; } diff --git a/source/blender/draw/engines/eevee_next/shaders/eevee_sampling_lib.glsl b/source/blender/draw/engines/eevee_next/shaders/eevee_sampling_lib.glsl index 0c7bbaa9dc2..0eea4a5ff33 100644 --- a/source/blender/draw/engines/eevee_next/shaders/eevee_sampling_lib.glsl +++ b/source/blender/draw/engines/eevee_next/shaders/eevee_sampling_lib.glsl @@ -9,7 +9,7 @@ /* -------------------------------------------------------------------- */ /** \name Sampling data. * - * Return a random values from Low Discrepency Sequence in [0..1) range. + * Return a random values from Low Discrepancy Sequence in [0..1) range. * This value is uniform (constant) for the whole scene sample. * You might want to couple it with a noise function. * \{ */ diff --git a/source/blender/draw/engines/eevee_next/shaders/eevee_velocity_lib.glsl b/source/blender/draw/engines/eevee_next/shaders/eevee_velocity_lib.glsl index c0a5b976810..8d02609fedc 100644 --- a/source/blender/draw/engines/eevee_next/shaders/eevee_velocity_lib.glsl +++ b/source/blender/draw/engines/eevee_next/shaders/eevee_velocity_lib.glsl @@ -47,7 +47,7 @@ vec4 velocity_surface(vec3 P_prv, vec3 P, vec3 P_nxt) */ vec4 velocity_background(vec3 vV) { - /* Only transform direction to avoid loosing precision. */ + /* Only transform direction to avoid losing precision. */ vec3 V = transform_direction(camera_curr.viewinv, vV); /* NOTE: We don't use the drw_view.winmat to avoid adding the TAA jitter to the velocity. */ vec2 prev_uv = project_point(camera_prev.winmat, V).xy; |