From fb7159ac23c66b3b864ef4a239f4bf6a484376cd Mon Sep 17 00:00:00 2001 From: luboslenco Date: Mon, 18 May 2026 09:08:34 +0200 Subject: [PATCH] paint: path layer fixes --- paint/sources/uniforms.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/paint/sources/uniforms.c b/paint/sources/uniforms.c index a7865013..c263f71d 100644 --- a/paint/sources/uniforms.c +++ b/paint/sources/uniforms.c @@ -54,7 +54,7 @@ f32 uniforms_ext_f32_link(object_t *object, material_data_t *mat, char *link) { } else if (string_equals(link, "_brush_opacity")) { f32 val = g_context->brush_opacity * g_context->brush_nodes_opacity; - if (g_config->pressure_opacity && pen_down("tip")) { + if (g_config->pressure_opacity && pen_down("tip") && !slot_layer_is_path(g_context->layer)) { val *= pen_pressure * g_config->pressure_sensitivity; } return val; @@ -65,7 +65,7 @@ f32 uniforms_ext_f32_link(object_t *object, material_data_t *mat, char *link) { return 1.0; } f32 val = fmaxf((g_context->brush_hardness * g_context->brush_nodes_hardness) - 0.02, 0.0); - if (g_config->pressure_hardness && pen_down("tip")) { + if (g_config->pressure_hardness && pen_down("tip") && !slot_layer_is_path(g_context->layer)) { val *= pen_pressure * g_config->pressure_sensitivity; } val *= val; @@ -154,7 +154,7 @@ vec2_t uniforms_ext_vec2_link(object_t *object, material_data_t *mat, char *link f32 brush_angle = g_context->brush_angle + g_context->brush_nodes_angle; f32 angle = g_context->layer->fill_material != NULL ? g_context->layer->angle : brush_angle; angle *= (math_pi() / 180.0); - if (g_config->pressure_angle && pen_down("tip")) { + if (g_config->pressure_angle && pen_down("tip") && !slot_layer_is_path(g_context->layer)) { angle *= pen_pressure * g_config->pressure_sensitivity; } return (vec2_t){math_cos(-angle), math_sin(-angle)};