Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

== comparisons using float numbers #49

Closed
LorenzMeier opened this issue May 28, 2015 · 0 comments
Closed

== comparisons using float numbers #49

LorenzMeier opened this issue May 28, 2015 · 0 comments

Comments

@LorenzMeier
Copy link
Member

@dominiho Several lines, including this one do float comparisons:

6d584340 (dominiho      2014-10-27 13:27:01 +0100 480)                  if(global_data.param[PARAM_SONAR_FILTERED])

You can fix this by using:

static_cast<int>(global_data.param[PARAM_SONAR_FILTERED] + 0.5f)
kevinmehall added a commit to kevinmehall/Flow that referenced this issue Nov 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants