41 QgsVector operator*(
double scalar )
const;
42 QgsVector operator/(
double scalar )
const;
44 double length()
const;
52 double angle(
void )
const;
86 : m_x( point.x() ), m_y( point.y() )
94 : m_x( point.x() ), m_y( point.y() )
117 void set(
double x,
double y )
149 QString toString(
int thePrecision )
const;
160 QString toDegreesMinutesSeconds(
int thePrecision,
const bool useSuffix =
true,
const bool padded =
false )
const;
171 QString toDegreesMinutes(
int thePrecision,
const bool useSuffix =
true,
const bool padded =
false )
const;
181 double sqrDist(
double x,
double y )
const;
184 double sqrDist(
const QgsPoint& other )
const;
190 double azimuth(
const QgsPoint& other );
198 bool compare(
const QgsPoint &other,
double epsilon = 4 * DBL_EPSILON )
const;
207 void multiply(
const double& scalar );
239 if (( p1.
x() == p2.
x() ) && ( p1.
y() == p2.
y() ) )
255 uint h1 =
qHash(( quint64 )p.m_x );
256 uint h2 =
qHash(( quint64 )p.m_y );
257 hash = h1 ^( h2 << 1 );
bool operator!=(const QgsFeatureIterator &fi1, const QgsFeatureIterator &fi2)
QgsPoint & operator-=(const QgsVector &v)
QgsVector operator-(const QgsPoint &p) const
double x() const
Get the x value of the point.
QgsPoint operator+(const QgsVector &v) const
QgsPoint()
Default constructor.
const double DEFAULT_SEGMENT_EPSILON
Default snapping tolerance for segments.
QgsPoint(const QPoint &point)
Create a point from a QPoint.
QString toString() const
String representation of the point (x,y)
void set(double x, double y)
Sets the x and y value of the point.
A class to represent a point.
double ANALYSIS_EXPORT angle(Point3D *p1, Point3D *p2, Point3D *p3, Point3D *p4)
Calculates the angle between two segments (in 2 dimension, z-values are ignored)
QByteArray toLocal8Bit() const
A class to represent a vector.
void setX(double x)
Sets the x value of the point.
void setY(double y)
Sets the y value of the point.
std::ostream & operator<<(std::ostream &os, const QgsPoint &p)
QgsPoint(const QPointF &point)
Create a point from a QPointF.
QgsPoint operator-(const QgsVector &v) const
QgsPoint(double x, double y)
Create a point from x,y coordinates.
double y() const
Get the y value of the point.
QgsPoint & operator+=(const QgsVector &v)
uint qHash(const QgsPoint &p)
bool operator==(const QgsPoint &p1, const QgsPoint &p2)