Skip to content

Commit

Permalink
Clean ViewProviderRobotObject.cpp
Browse files Browse the repository at this point in the history
Clean file
  • Loading branch information
mosfet80 authored Dec 27, 2024
1 parent 7083362 commit cbe7542
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions src/Mod/Robot/Gui/ViewProviderRobotObject.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,10 @@ ViewProviderRobotObject::ViewProviderRobotObject()

pcRobotRoot = new Gui::SoFCSelection();
pcRobotRoot->highlightMode = Gui::SoFCSelection::OFF;
// pcRobotRoot->selectionMode = Gui::SoFCSelection::SEL_OFF;
// pcRobotRoot->style = Gui::SoFCSelection::BOX;
pcRobotRoot->ref();

pcSimpleRoot = new Gui::SoFCSelection();
pcSimpleRoot->highlightMode = Gui::SoFCSelection::OFF;
// pcSimpleRoot->selectionMode = Gui::SoFCSelection::SEL_OFF;
pcSimpleRoot->ref();

pcOffRoot = new SoGroup();
Expand Down Expand Up @@ -368,18 +365,13 @@ void ViewProviderRobotObject::updateData(const App::Property* prop)
toolShape->setTransformation(
(robObj->Tcp.getValue() * (robObj->ToolBase.getValue().inverse())).toMatrix());
}
// pcTcpTransform->translation =
// SbVec3f(loc.getPosition().x,loc.getPosition().y,loc.getPosition().z);
// pcTcpTransform->rotation =
// SbRotation(loc.getRotation()[0],loc.getRotation()[1],loc.getRotation()[2],loc.getRotation()[3]);
}
else if (prop == &robObj->ToolShape) {
App::DocumentObject* o = robObj->ToolShape.getValue<App::DocumentObject*>();

if (o
&& (o->isDerivedFrom(Part::Feature::getClassTypeId())
|| o->isDerivedFrom(App::VRMLObject::getClassTypeId()))) {
// Part::Feature *p = dynamic_cast<Part::Feature *>(o);
toolShape = Gui::Application::Instance->getViewProvider(o);
toolShape->setTransformation(
(robObj->Tcp.getValue() * (robObj->ToolBase.getValue().inverse())).toMatrix());
Expand All @@ -389,6 +381,7 @@ void ViewProviderRobotObject::updateData(const App::Property* prop)
}
}
}

void ViewProviderRobotObject::setAxisTo(float A1,
float A2,
float A3,
Expand Down Expand Up @@ -444,7 +437,10 @@ void ViewProviderRobotObject::DraggerMotionCallback(SoDragger* dragger)
SbVec3f center(Tcp.getPosition().x, Tcp.getPosition().y, Tcp.getPosition().z);
M.getTransform(translation, rotation, scaleFactor, scaleOrientation);
rotation.getValue(q0, q1, q2, q3);
// Base::Console().Message("M %f %f %f\n", M[3][0], M[3][1], M[3][2]);
Base::Rotation rot(q0, q1, q2, q3);
Base::Vector3d pos(translation[0], translation[1], translation[2]);
robObj->Tcp.setValue(Base::Placement(pos, rot));
}ssage("M %f %f %f\n", M[3][0], M[3][1], M[3][2]);

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

a type specifier is required for all declarations

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'M'

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'M'

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'M'

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

a type specifier is required for all declarations [clang-diagnostic-error]

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'M' [clang-diagnostic-error]

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'M' [clang-diagnostic-error]

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'M' [clang-diagnostic-error]

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

expected constructor, destructor, or type conversion before '(' token

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

a type specifier is required for all declarations

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

use of undeclared identifier 'M'

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

use of undeclared identifier 'M'

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

use of undeclared identifier 'M'

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

missing type specifier - int assumed. Note: C++ does not support default-int

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'M': undeclared identifier

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'M': undeclared identifier

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'M': undeclared identifier

Check failure on line 443 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'initializing': cannot convert from 'const char [12]' to 'int'
Base::Rotation rot(q0, q1, q2, q3);

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q0'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q1'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q2'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q3'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q0' [clang-diagnostic-error]

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q1' [clang-diagnostic-error]

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q2' [clang-diagnostic-error]

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'q3' [clang-diagnostic-error]

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'q0' was not declared in this scope; did you mean 'y0'?

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'q1' was not declared in this scope; did you mean 'y1'?

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'q2' was not declared in this scope; did you mean 'q23'?

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'q3' was not declared in this scope; did you mean 'q23'?

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

unknown type name 'q0'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

unknown type name 'q1'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

unknown type name 'q2'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

unknown type name 'q3'

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'q0': undeclared identifier

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'q1': undeclared identifier

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'q2': undeclared identifier

Check failure on line 444 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'q3': undeclared identifier
Base::Vector3d pos(translation[0], translation[1], translation[2]);

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'translation'; did you mean 'Eigen::Translation'?

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'translation'

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

unknown type name 'translation' [clang-diagnostic-error]

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Lint / Lint

use of undeclared identifier 'translation'; did you mean 'Eigen::Translation'? [clang-diagnostic-error]

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'translation' was not declared in this scope; did you mean 'gp_Translation'?

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'translation' was not declared in this scope; did you mean 'gp_Translation'?

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'translation' was not declared in this scope; did you mean 'gp_Translation'?

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

use of undeclared identifier 'translation'; did you mean 'Eigen::Translation'?

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (macos-latest)

unknown type name 'translation'

Check failure on line 445 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (windows-latest)

'translation': undeclared identifier
robObj->Tcp.setValue(Base::Placement(pos, rot));

Check failure on line 446 in src/Mod/Robot/Gui/ViewProviderRobotObject.cpp

View workflow job for this annotation

GitHub Actions / Pixi / build_with_pixi (ubuntu-latest)

'robObj' does not name a type
Expand Down

0 comments on commit cbe7542

Please sign in to comment.