mirror of
https://github.com/orbbec/OrbbecSDK_ROS2.git
synced 2026-10-09 14:27:02 +08:00
feat: update publisher topics to remove camera name prefix for depth extrinsics
This commit is contained in:
@@ -2326,32 +2326,32 @@ void OBCameraNode::setupPublishers() {
|
|||||||
if (enable_stream_[DEPTH] && enable_stream_[INFRA0] && enable_publish_extrinsic_) {
|
if (enable_stream_[DEPTH] && enable_stream_[INFRA0] && enable_publish_extrinsic_) {
|
||||||
depth_to_other_extrinsics_publishers_[INFRA0] =
|
depth_to_other_extrinsics_publishers_[INFRA0] =
|
||||||
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
||||||
"/" + camera_name_ + "/depth_to_ir", extrinsics_qos);
|
"depth_to_ir", extrinsics_qos);
|
||||||
}
|
}
|
||||||
if (enable_stream_[DEPTH] && enable_stream_[COLOR] && enable_publish_extrinsic_) {
|
if (enable_stream_[DEPTH] && enable_stream_[COLOR] && enable_publish_extrinsic_) {
|
||||||
depth_to_other_extrinsics_publishers_[COLOR] =
|
depth_to_other_extrinsics_publishers_[COLOR] =
|
||||||
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
||||||
"/" + camera_name_ + "/depth_to_color", extrinsics_qos);
|
"depth_to_color", extrinsics_qos);
|
||||||
}
|
}
|
||||||
if (enable_stream_[DEPTH] && enable_stream_[INFRA1] && enable_publish_extrinsic_) {
|
if (enable_stream_[DEPTH] && enable_stream_[INFRA1] && enable_publish_extrinsic_) {
|
||||||
depth_to_other_extrinsics_publishers_[INFRA1] =
|
depth_to_other_extrinsics_publishers_[INFRA1] =
|
||||||
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
||||||
"/" + camera_name_ + "/depth_to_left_ir", extrinsics_qos);
|
"depth_to_left_ir", extrinsics_qos);
|
||||||
}
|
}
|
||||||
if (enable_stream_[DEPTH] && enable_stream_[INFRA2] && enable_publish_extrinsic_) {
|
if (enable_stream_[DEPTH] && enable_stream_[INFRA2] && enable_publish_extrinsic_) {
|
||||||
depth_to_other_extrinsics_publishers_[INFRA2] =
|
depth_to_other_extrinsics_publishers_[INFRA2] =
|
||||||
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
||||||
"/" + camera_name_ + "/depth_to_right_ir", extrinsics_qos);
|
"depth_to_right_ir", extrinsics_qos);
|
||||||
}
|
}
|
||||||
if (enable_stream_[DEPTH] && enable_stream_[ACCEL] && enable_publish_extrinsic_) {
|
if (enable_stream_[DEPTH] && enable_stream_[ACCEL] && enable_publish_extrinsic_) {
|
||||||
depth_to_other_extrinsics_publishers_[ACCEL] =
|
depth_to_other_extrinsics_publishers_[ACCEL] =
|
||||||
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
||||||
"/" + camera_name_ + "/depth_to_accel", extrinsics_qos);
|
"depth_to_accel", extrinsics_qos);
|
||||||
}
|
}
|
||||||
if (enable_stream_[DEPTH] && enable_stream_[GYRO] && enable_publish_extrinsic_) {
|
if (enable_stream_[DEPTH] && enable_stream_[GYRO] && enable_publish_extrinsic_) {
|
||||||
depth_to_other_extrinsics_publishers_[GYRO] =
|
depth_to_other_extrinsics_publishers_[GYRO] =
|
||||||
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
node_->create_publisher<orbbec_camera_msgs::msg::Extrinsics>(
|
||||||
"/" + camera_name_ + "/depth_to_gyro", extrinsics_qos);
|
"depth_to_gyro", extrinsics_qos);
|
||||||
}
|
}
|
||||||
filter_status_pub_ =
|
filter_status_pub_ =
|
||||||
node_->create_publisher<std_msgs::msg::String>("depth_filter_status", extrinsics_qos);
|
node_->create_publisher<std_msgs::msg::String>("depth_filter_status", extrinsics_qos);
|
||||||
|
|||||||
Reference in New Issue
Block a user