src/types/vertex.cpp

changeset 1371
b8df4748d04e
parent 1370
c6d5ba08c62c
child 1390
3eace926af7f
equal deleted inserted replaced
1370:c6d5ba08c62c 1371:b8df4748d04e
198 { 198 {
199 return (one - other).length(); 199 return (one - other).length();
200 } 200 }
201 201
202 /* 202 /*
203 * Returns a vertex with all coordinates inverted.
204 */
205 Vertex operator-(const Vertex& vertex)
206 {
207 return {-vertex.x, -vertex.y, -vertex.z};
208 }
209
210 /*
203 * Inserts this vertex into a data stream. This is needed for vertices to be 211 * Inserts this vertex into a data stream. This is needed for vertices to be
204 * stored in QSettings. 212 * stored in QSettings.
205 */ 213 */
206 QDataStream& operator<<(QDataStream& out, const Vertex& vertex) 214 QDataStream& operator<<(QDataStream& out, const Vertex& vertex)
207 { 215 {

mercurial