@2ROS0: "(I don't want to do that for some smaller tasks)" Exactly the same with me.
I am looking for an API programming language equivalent of $ rosrun tf tf_echo [frame1] [frame2]
I'm also trying to see how this command works:
void transformPoint (const std::string &target_frame, const Stamped< tf::Point > &stamped_in, Stamped< tf::Point > &stamped_out) const
but I don't see an indication for the current/reference frame which is not too good.
Originally posted by BluPlana with karma: 26 on 2017-02-23
This answer was ACCEPTED on the original site
Post score: 0
Original comments
Comment by gvdhoorn on 2017-02-24:\
I don't see an indication for the current/reference frame
The input to transformPoint(..)
is a Stamped<tf::Point>
. Stamped in ROS parlance means: "with a header", which implies that the frame_id
of the hdr is valid. That is the source frame. target_frame
is the .. target.
Comment by gvdhoorn on 2017-02-24:
Note: the Stamped
suffix is used on msgs to indicate that it has a Header
. In this case the terminology / naming convention was carried over, but Stamped
is not a msg def. Member names are identical though: api/Stamped.
Comment by BluPlana on 2017-02-24:
@gvdhoorn: Thanks. Your response is really helpful!
for points that are not stamped, what happens?
Comment by BluPlana on 2017-02-24:
However, for points without stamps, how does one know the operating frame? My point doesn't have any stamp, but I'm sure it is defined in the /world. However, when I perform Inverse kinematics on my KDL chain to that point, my IK_solver seems to take the endeff to the point in the chain_root_frame
Comment by gvdhoorn on 2017-02-24:\
for points that are not stamped, what happens?
well, for this particular overload you'll get a compiler error.
But in general you'll have to either convert your Point
to a Stamped
version (ie: by providing the required info), or use one of the more suited overloads.