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:
authorJacques Lucke <jacques@blender.org>2021-09-27 16:10:28 +0300
committerJacques Lucke <jacques@blender.org>2021-09-27 16:10:28 +0300
commit2bd020521578549eb47c58c7984c9a35b7c35cd8 (patch)
tree545db3268014462b036362a09675f9c96a2c7d76 /source/blender/gpu
parent8fecc2a8525467ee2fbbaae16ddbbc10b3050d46 (diff)
Geometry Nodes: make field links thinner than other links
This makes it easier to spot which links contain fields and which contain data. Actually, the patch makes all other links a bit thicker. However, with soon-to-be-implemented theme changes, the perceived thickness will be the same as before. This is part of T91563. Differential Revision: https://developer.blender.org/D12646
Diffstat (limited to 'source/blender/gpu')
-rw-r--r--source/blender/gpu/shaders/gpu_shader_2D_nodelink_vert.glsl4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/gpu/shaders/gpu_shader_2D_nodelink_vert.glsl b/source/blender/gpu/shaders/gpu_shader_2D_nodelink_vert.glsl
index aae7f641af8..2194d23a4ea 100644
--- a/source/blender/gpu/shaders/gpu_shader_2D_nodelink_vert.glsl
+++ b/source/blender/gpu/shaders/gpu_shader_2D_nodelink_vert.glsl
@@ -19,6 +19,7 @@ in vec2 P3;
in ivec4 colid_doarrow;
in ivec2 domuted;
in float dim_factor;
+in float thickness;
uniform vec4 colors[6];
@@ -41,6 +42,7 @@ uniform vec4 colors[3];
uniform bool doArrow;
uniform bool doMuted;
uniform float dim_factor;
+uniform float thickness;
# define colShadow colors[0]
# define colStart colors[1]
@@ -103,7 +105,7 @@ void main(void)
finalColor[3] *= dim_factor;
/* Expand into a line */
- gl_Position.xy += exp_axis * expandSize * expand_dist;
+ gl_Position.xy += exp_axis * expandSize * expand_dist * thickness;
/* If the link is not muted or is not a reroute arrow the points are squashed to the center of
* the line. Magic numbers are defined in drawnode.c */