MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / getDirection

Method getDirection

src/App/Datums.cpp:104–118  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

102}
103
104Base::Vector3d DatumElement::getDirection() const
105{
106 Base::Vector3d dir(baseDir);
107 Base::Placement plc = Placement.getValue();
108 Base::Rotation rot = plc.getRotation();
109 rot.multVec(dir, dir);
110
111 const auto* lcs = getLCS();
112 if (lcs && !lcs->isOrigin()) {
113 Base::Rotation lcsRot = lcs->Placement.getValue().getRotation();
114 lcsRot.multVec(dir, dir);
115 }
116
117 return dir;
118}
119
120Base::Vector3d DatumElement::getBaseDirection() const
121{

Callers 1

TEST_FFunction · 0.45

Calls 3

getValueMethod · 0.45
getRotationMethod · 0.45
multVecMethod · 0.45

Tested by

no test coverage detected