ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
2

Passing a pointer as a ROS msg

asked 2012-04-08 09:49:23 -0600

Alekzander gravatar image

updated 2014-04-20 14:09:18 -0600

ngrennan gravatar image

Hello, im creating a basic vision system which implements filters through a pipeline structure. My point cloud is grabbed by a kinect. The thing is i would like t send just a pointer to the cloud as a ROS message, in order to get a faster and more efficient processing. Is there a way to do this? thanks

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
9

answered 2012-04-08 10:17:39 -0600

Mac gravatar image

updated 2012-04-11 05:22:40 -0600

...not as such. ROS messages are transmitted over the network; as a result, "passing a pointer" doesn't make any sense.

But wait, there's more!

One possibility is to just implement your pipeline in a single node; then it can pass pointers around because it's all in one process.

Another is to use nodelets, which offer a way of defining something that behaves like a node, but lets you have several in the same process; these were devised to solve exactly the problem you're talking about.

A third option is ecto; where ROS is by-design asynchronous (which makes multi-input perceptual pipelines very painful), ecto is by-design synchronous, to make such pipelines easy. Ecto's still in heavy development, but it'll be seriously cool when it's done.

edit flag offensive delete link more
0

answered 2012-04-08 10:26:51 -0600

Alekzander gravatar image

Thank you very much, I didnt know the difference between nodes and nodelets, ill look into it. Thanks again.

edit flag offensive delete link more

Comments

Glad to help. Give me an upvote, and accept the answer?

Mac gravatar image Mac  ( 2012-04-09 06:18:29 -0600 )edit

And use comments instead of answers :)

felix k gravatar image felix k  ( 2012-04-09 22:53:13 -0600 )edit

Question Tools

Stats

Asked: 2012-04-08 09:49:23 -0600

Seen: 2,403 times

Last updated: Apr 11 '12