From 2c6788acf1de0ccf7bad71f04a804977bddba4dd Mon Sep 17 00:00:00 2001 From: Raphael Graf Date: Thu, 30 May 2024 19:56:03 +0200 Subject: [PATCH] Fix cast to bool type in get_param_value() --- include/frei0r.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/frei0r.hpp b/include/frei0r.hpp index 5eed2dcf..ef12be4f 100644 --- a/include/frei0r.hpp +++ b/include/frei0r.hpp @@ -101,7 +101,7 @@ namespace frei0r { case F0R_PARAM_BOOL : *static_cast(param) - = *static_cast(ptr) > 0.5 ? 1.0 : 0.0; + = *static_cast(ptr) ? 1.0 : 0.0; break; case F0R_PARAM_DOUBLE: *static_cast(param)