Thread
:
remainder function
View Single Post
#
15
01-02-2013, 14:12
Ether
systems engineer (retired)
no team
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,102
Re: remainder function
Quote:
Originally Posted by
1075guy
OK, so do this instead:
Code:
output = (719 % 360 > 180) ? (-360 + (719 % 360)) : (719 % 360);
Fails when angle = -359. Doesn't work with floats.
Ether
View Public Profile
Find all posts by Ether
Find CD-Media Photos by Ether
Find CD-Media Papers by Ether