--- a/src/types/vertex.cpp Sat May 26 17:28:15 2018 +0300 +++ b/src/types/vertex.cpp Wed May 30 22:31:06 2018 +0300 @@ -92,6 +92,11 @@ return ::format("%1 %2 %3", this->x, this->y, this->z); } +Vertex Vertex::fromVector(const QVector3D& vector) +{ + return {vector.x(), vector.y(), vector.z()}; +} + Vertex Vertex::operator*(qreal scalar) const { return {this->x * scalar, this->y * scalar, this->z * scalar};