RoboJackets / robocup-software

Georgia Tech RoboJackets Software for the RoboCup Small Size League
Apache License 2.0
178 stars 187 forks source link

Normalizing Angles #964

Open Jason27chan opened 7 years ago

Jason27chan commented 7 years ago

Some places (circle_near_ball being on example) use a weird way to normalize angles when it should use Geometry2D's

Jason27chan commented 6 years ago

@jgkamat I cant find a function to normalize angles in Geometry2D. Can we close this issue or make this an issue to make a function to normalize in Geometry2D?

JNeiger commented 6 years ago

https://github.com/RoboJackets/robocup-software/blob/master/common/Utils.hpp#L57 Is this maybe what we were talking about?

ashaw596 commented 6 years ago

Also since its a common use case. https://github.com/RoboJackets/robocup-software/blob/8871c0ea6c982ccbc527ae5695441ed1ff0f8d8a/common/Geometry2d/Point.hpp#L345 This should be used to get a normalized angle between directional angles.