Forum Discussion
Altera_Forum
Honored Contributor
19 years agoround function
Hi, I want to round a floating point number before I cast it to an int. So, round 3.6 to 4.0 I try using the function round and the compiler buys it but when I do round(3.6) or r...
Altera_Forum
Honored Contributor
19 years agoYeah, I *guess*.
Not quite as elegant as round but truthfully it will probably execute much quicker than any round function anyway. It bothers me that round seems to be defined but doesn't really work the way I expect it to but after writing code for Nios for a year I should not be surprised. Thank you for the response BadOmen. Mike