Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/draw/modes/shaders/object_lightprobe_grid_vert.glsl')
-rw-r--r--source/blender/draw/modes/shaders/object_lightprobe_grid_vert.glsl23
1 files changed, 11 insertions, 12 deletions
diff --git a/source/blender/draw/modes/shaders/object_lightprobe_grid_vert.glsl b/source/blender/draw/modes/shaders/object_lightprobe_grid_vert.glsl
index bcdf5adca55..61da94dd433 100644
--- a/source/blender/draw/modes/shaders/object_lightprobe_grid_vert.glsl
+++ b/source/blender/draw/modes/shaders/object_lightprobe_grid_vert.glsl
@@ -16,19 +16,18 @@ flat out uint finalId;
void main()
{
- vec3 ls_cell_location;
- /* Keep in sync with update_irradiance_probe */
- ls_cell_location.z = float(gl_VertexID % grid_resolution.z);
- ls_cell_location.y = float((gl_VertexID / grid_resolution.z) % grid_resolution.y);
- ls_cell_location.x = float(gl_VertexID / (grid_resolution.z * grid_resolution.y));
+ vec3 ls_cell_location;
+ /* Keep in sync with update_irradiance_probe */
+ ls_cell_location.z = float(gl_VertexID % grid_resolution.z);
+ ls_cell_location.y = float((gl_VertexID / grid_resolution.z) % grid_resolution.y);
+ ls_cell_location.x = float(gl_VertexID / (grid_resolution.z * grid_resolution.y));
- vec3 ws_cell_location = corner +
- (increment_x * ls_cell_location.x +
- increment_y * ls_cell_location.y +
- increment_z * ls_cell_location.z);
+ vec3 ws_cell_location = corner +
+ (increment_x * ls_cell_location.x + increment_y * ls_cell_location.y +
+ increment_z * ls_cell_location.z);
- gl_Position = ViewProjectionMatrix * vec4(ws_cell_location, 1.0);
- gl_PointSize = 2.0f;
+ gl_Position = ViewProjectionMatrix * vec4(ws_cell_location, 1.0);
+ gl_PointSize = 2.0f;
- finalId = uint(baseId + call_id);
+ finalId = uint(baseId + call_id);
}