Skip to content

Commit

Permalink
Merge pull request #2 from Extend-Robotics/feature/respect-external-n…
Browse files Browse the repository at this point in the history
…amespace

correctly respect external ROS namespace
  • Loading branch information
bmegli authored Jan 16, 2024
2 parents 0e3da92 + f4449a5 commit 6061471
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/ros_setup.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -256,14 +256,14 @@ void OBCameraNode::setupPublishers() {
continue;
}
std::string name = stream_name_[stream_index];
std::string topic_name = "/" + camera_name_ + "/" + name + "/image_raw";
std::string topic_name = camera_name_ + "/" + name + "/image_raw";
image_transport::SubscriberStatusCallback image_subscribed_cb =
boost::bind(&OBCameraNode::imageSubscribedCallback, this, stream_index);
image_transport::SubscriberStatusCallback image_unsubscribed_cb =
boost::bind(&OBCameraNode::imageUnsubscribedCallback, this, stream_index);
image_publishers_[stream_index] = image_transport_.advertise(
topic_name, 1, image_subscribed_cb, image_unsubscribed_cb);
topic_name = "/" + camera_name_ + "/" + name + "/camera_info";
topic_name = camera_name_ + "/" + name + "/camera_info";
ros::SubscriberStatusCallback camera_info_subscribed_cb =
boost::bind(&OBCameraNode::imageSubscribedCallback, this, stream_index);
ros::SubscriberStatusCallback camera_info_unsubscribed_cb =
Expand Down

0 comments on commit 6061471

Please sign in to comment.