From 1344bec7bbd7bf47ae132e14aaca6377276ced8d Mon Sep 17 00:00:00 2001 From: Jonas Holmberg Date: Thu, 12 Mar 2026 15:24:14 +0100 Subject: [PATCH] filter-graph: set min, max and def values for ramp Set min, max and def values for the control ports of ramp plugin to avoid clamping all control values to 0. --- spa/plugins/filter-graph/plugin_builtin.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/spa/plugins/filter-graph/plugin_builtin.c b/spa/plugins/filter-graph/plugin_builtin.c index a16e4a7fc..f3a0a0946 100644 --- a/spa/plugins/filter-graph/plugin_builtin.c +++ b/spa/plugins/filter-graph/plugin_builtin.c @@ -2486,10 +2486,12 @@ static struct spa_fga_port ramp_ports[] = { { .index = 1, .name = "Start", .flags = SPA_FGA_PORT_INPUT | SPA_FGA_PORT_CONTROL, + .def = 0.0f, .min = -FLT_MAX, .max = FLT_MAX }, { .index = 2, .name = "Stop", .flags = SPA_FGA_PORT_INPUT | SPA_FGA_PORT_CONTROL, + .def = 1.0f, .min = -FLT_MAX, .max = FLT_MAX }, { .index = 3, .name = "Current", @@ -2498,6 +2500,7 @@ static struct spa_fga_port ramp_ports[] = { { .index = 4, .name = "Duration (s)", .flags = SPA_FGA_PORT_INPUT | SPA_FGA_PORT_CONTROL, + .def = 1.0f, .min = 0.0f, .max = FLT_MAX }, };