src/mathfunctions.cpp

changeset 1073
a0a0d581309b
parent 1072
9ce9496427f2
child 1079
67c6e5d32e68
equal deleted inserted replaced
1072:9ce9496427f2 1073:a0a0d581309b
31 vertex.transform (transformationMatrix, Origin); 31 vertex.transform (transformationMatrix, Origin);
32 vertex += rotationPoint; 32 vertex += rotationPoint;
33 } 33 }
34 34
35 35
36 void MathFunctions::rotateObjects(int l, int m, int n, double angle, const LDObjectList& objects) const 36 void MathFunctions::rotateObjects(int l, int m, int n, double angle, const QVector<LDObject*>& objects) const
37 { 37 {
38 Vertex rotationPoint = getRotationPoint (objects); 38 Vertex rotationPoint = getRotationPoint (objects);
39 double cosAngle = cos(angle); 39 double cosAngle = cos(angle);
40 double sinAngle = sin(angle); 40 double sinAngle = sin(angle);
41 41
81 } 81 }
82 } 82 }
83 } 83 }
84 84
85 85
86 Vertex MathFunctions::getRotationPoint(const LDObjectList& objs) const 86 Vertex MathFunctions::getRotationPoint(const QVector<LDObject*>& objs) const
87 { 87 {
88 switch (RotationPoint (m_config->rotationPointType())) 88 switch (RotationPoint (m_config->rotationPointType()))
89 { 89 {
90 case ObjectOrigin: 90 case ObjectOrigin:
91 { 91 {

mercurial