GithubHelp home page GithubHelp logo

Missing convertions about geometry2 HOT 7 OPEN

ros avatar ros commented on July 1, 2024
Missing convertions

from geometry2.

Comments (7)

vrabaud avatar vrabaud commented on July 1, 2024

right, this documentation needs advertisement, like on the wiki.
You mention a few types, but what would they convert to ? Thx

from geometry2.

mistoll avatar mistoll commented on July 1, 2024

Nice convertions would be:
Eigen::Quaterniond <=> geometry_msgs::Quaternion
Eigen::Vector3 <=> geometry_msgs::Vector, geometry_msgs::Point
Eigen::Matrix3d <=> geometry_msgs::Matrix
Also great (but might be incompatible)
Eigen::Matrixxd <=> geometry_msgs covariances (e.g. float64[36])

from geometry2.

vrabaud avatar vrabaud commented on July 1, 2024

Ok, if you have any other types that you'd like to have converted, please add in here.

Eigen::Vector3 <=> geometry_msgs::Vector, geometry_msgs::Point

is a tricky one: a vector is not the same things as a point in ROS (a vector is a direction, that is therefore not translated when a transform is applied to it, cf https://github.com/ros/geometry_experimental/blob/jade-devel/tf2_geometry_msgs/include/tf2_geometry_msgs/tf2_geometry_msgs.h#L77 )

Same with the matrix and the covariance matrix: the info is the same, but not the semantic (same with pose and transform).

Anyway, I need to write the wiki page about conversion and utils.h, and add those conversions above that make sense.

from geometry2.

mistoll avatar mistoll commented on July 1, 2024

I wasn't aware of the doTransform method. That complicates things.

So what do you recommend for those non-bijective mappings? Should everyone implement them application-specific or not use convert at all?

from geometry2.

tfoote avatar tfoote commented on July 1, 2024

If it's not bijective it shouldn't use the convert method. You should
define a method which captures the semantic meaning, potentially
application specific, potentially somewhat generic and shareable between
similar applications as any function can be done already.

On Mon, Aug 17, 2015 at 6:44 AM, mistoll [email protected] wrote:

I wasn't aware of the doTransform method. That complicates things.

So what do you recommend for those non-bijective mappings? Should everyone
implement them application-specific or not use convert at all?


Reply to this email directly or view it on GitHub
#116 (comment)
.

from geometry2.

cmansley avatar cmansley commented on July 1, 2024

I agree with @tfoote, but we should define which conversions are the bijective ones and which are not. Because geometry_msgs::Pose is being converted into tf2::Transform in tf2_geometry_msgs.h, but it could have easily been geometry_msgs::Transform instead.

And these conversion functions are replicated in the buffer_core.cpp.

So, I guess there are two things.

  • When do we use the convert interface defined in convert.h?
  • What is the policy for defining "custom" methods?

from geometry2.

tfoote avatar tfoote commented on July 1, 2024

#202 adds the primatives for geometry_msgs

from geometry2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.