65 if( aVector.
x == 0.0 && aVector.
y == 0.0 )
69 else if( aVector.
y == 0.0 )
76 else if( aVector.
x == 0.0 )
78 if( aVector.
y >= 0.0 )
83 else if( aVector.
x == aVector.
y )
85 if( aVector.
x >= 0.0 )
90 else if( aVector.
x == -aVector.
y )
92 if( aVector.
x >= 0.0 )
107 if( aVector.
x == 0 && aVector.
y == 0 )
111 else if( aVector.
y == 0 )
118 else if( aVector.
x == 0 )
125 else if( aVector.
x == aVector.
y )
132 else if( aVector.
x == -aVector.
y )
191 if( thisNormalized.
AsDegrees() == -90.0 )
211 if(
test.m_value == 0.0 ||
test.m_value == 180.0 )
213 else if(
test.m_value == 90.0 )
215 else if(
test.m_value == 270.0 )
226 if(
test.m_value == 0.0 )
228 else if(
test.m_value == 180.0 )
230 else if(
test.m_value == 90.0 ||
test.m_value == 270.0 )
EDA_ANGLE NormalizeNegative()
static EDA_ANGLE m_Angle135
int AsTenthsOfADegree() const
bool IsParallelTo(EDA_ANGLE aAngle) const
static EDA_ANGLE m_Angle0
EDA_ANGLE(const VECTOR2I &aVector)
bool IsHorizontal() const
static EDA_ANGLE Arctan2(double y, double x)
EDA_ANGLE KeepUpright() const
static EDA_ANGLE m_Angle45
EDA_ANGLE & operator-=(const EDA_ANGLE &aAngle)
static EDA_ANGLE m_Angle180
EDA_ANGLE & operator+=(const EDA_ANGLE &aAngle)
static EDA_ANGLE m_Angle90
EDA_ANGLE(const VECTOR2D &aVector)
EDA_ANGLE(double aValue, EDA_ANGLE_T aAngleType)
Angles can be created in degrees, 1/10ths of a degree, or radians, and read as any of the angle types...
static EDA_ANGLE m_Angle270
static constexpr double DEGREES_TO_RADIANS
bool IsCardinal90() const
double m_value
value in degrees
static EDA_ANGLE Arctan(double x)
static EDA_ANGLE m_Angle360
static EDA_ANGLE Arcsin(double x)
EDA_ANGLE Normalized() const
static EDA_ANGLE Arccos(double x)
EDA_ANGLE operator/(const EDA_ANGLE &aAngleA, double aOperator)
bool operator>(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
static constexpr EDA_ANGLE & ANGLE_180
bool operator>=(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
EDA_ANGLE operator*(const EDA_ANGLE &aAngleA, double aOperator)
bool operator<=(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
static constexpr EDA_ANGLE & ANGLE_HORIZONTAL
std::ostream & operator<<(std::ostream &aStream, const EDA_ANGLE &aAngle)
static constexpr EDA_ANGLE & ANGLE_360
static constexpr EDA_ANGLE & ANGLE_VERTICAL
EDA_ANGLE operator-(const EDA_ANGLE &aAngle)
static constexpr EDA_ANGLE & ANGLE_45
bool operator<(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
static constexpr EDA_ANGLE & FULL_CIRCLE
bool operator==(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
static constexpr EDA_ANGLE & ANGLE_90
static constexpr EDA_ANGLE & ANGLE_0
static constexpr EDA_ANGLE & ANGLE_270
static constexpr EDA_ANGLE & ANGLE_135
EDA_ANGLE operator+(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
bool operator!=(const EDA_ANGLE &aAngleA, const EDA_ANGLE &aAngleB)
EDA_ANGLE abs(const EDA_ANGLE &aAngle)
constexpr ret_type KiROUND(fp_type v)
Round a floating point number to an integer using "round halfway cases away from zero".