1 #ifndef ABSTRACT_ROBOT_
2 #define ABSTRACT_ROBOT_
5 #include <tf2/LinearMath/Transform.h>
26 std::vector<tf2::Transform>
bounds_;
32 virtual std::string&
name()=0;
33 virtual tf2::Transform&
tf()=0;
34 virtual tf2::Vector3&
size()=0;
35 virtual tf2::Transform&
root_tf()=0;
36 virtual std::vector<tf2::Transform>&
bounds()=0;
41 inline void rotate(
float deg) {tf2::Quaternion rot; rot.setRPY(0,0,deg); tf2::Transform t(rot, tf2::Vector3(0,0,0));
tf_=
tf_* t;}
42 inline void translate(tf2::Vector3 t) {tf2::Transform
tf(tf2::Quaternion(0,0,0,1), t);
tf_*=
tf;}
45 virtual void workload_checker(std::vector<int>& count_vector, tf2::Transform& obj) =0;
55 float area_calculation(tf2::Transform& A, tf2::Transform& B, tf2::Transform& C);