QGIS API Documentation
3.26.3-Buenos Aires (65e4edfdad)
|
Go to the documentation of this file.
23 const double angle = std::atan2( mY, mX ) + rot;
24 const double len =
length();
30 const double len =
length();
34 throw QgsException( QStringLiteral(
"normalized vector of null vector undefined" ) );
Defines a QGIS exception class.
double angle() const SIP_HOLDGIL
Returns the angle of the vector in radians.
QgsVector rotateBy(double rot) const SIP_HOLDGIL
Rotates the vector by a specified angle.
QgsVector()=default
Default constructor for QgsVector.
QgsVector normalized() const SIP_THROW(QgsException)
Returns the vector's normalized (or "unit") vector (ie same angle but length of 1....
double length() const SIP_HOLDGIL
Returns the length of the vector.
A class to represent a vector. Currently no Z axis / 2.5D support is implemented.