Skip to content

Commit

Permalink
Fix cast to bool type in get_param_value()
Browse files Browse the repository at this point in the history
  • Loading branch information
rrrapha authored and jaromil committed Jul 22, 2024
1 parent e7fa53f commit 2c6788a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion include/frei0r.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ namespace frei0r
{
case F0R_PARAM_BOOL :
*static_cast<f0r_param_bool*>(param)
= *static_cast<f0r_param_bool*>(ptr) > 0.5 ? 1.0 : 0.0;
= *static_cast<bool*>(ptr) ? 1.0 : 0.0;
break;
case F0R_PARAM_DOUBLE:
*static_cast<f0r_param_double*>(param)
Expand Down

0 comments on commit 2c6788a

Please sign in to comment.