@@ -96,10 +96,10 @@ void log_imu(
96
96
" timestamp" ,
97
97
rclcpp::Time (msg->header .stamp .sec , msg->header .stamp .nanosec ).seconds ()
98
98
);
99
+
99
100
rec.log (entity_path + " /x" , rerun::Scalars (msg->linear_acceleration .x ));
100
101
rec.log (entity_path + " /y" , rerun::Scalars (msg->linear_acceleration .y ));
101
102
rec.log (entity_path + " /z" , rerun::Scalars (msg->linear_acceleration .z ));
102
-
103
103
}
104
104
105
105
void log_image (
@@ -427,14 +427,7 @@ void log_joint_state(
427
427
// Entity path format: /joint_angles/joint_name
428
428
std::string joint_entity_path = entity_path + " /joint_angles/" + joint_name;
429
429
430
- rec.log (
431
- joint_entity_path,
432
- rerun::Scalars (
433
- rerun::Collection<rerun::components::Scalar>::take_ownership (
434
- {rerun::components::Scalar (joint_position)}
435
- )
436
- )
437
- );
430
+ rec.log (joint_entity_path, rerun::Scalars (joint_position));
438
431
}
439
432
440
433
// Also log joint velocities if available
@@ -444,14 +437,7 @@ void log_joint_state(
444
437
double joint_velocity = msg->velocity [i];
445
438
446
439
std::string velocity_entity_path = entity_path + " /joint_velocities/" + joint_name;
447
- rec.log (
448
- velocity_entity_path,
449
- rerun::Scalars (
450
- rerun::Collection<rerun::components::Scalar>::take_ownership (
451
- {rerun::components::Scalar (joint_velocity)}
452
- )
453
- )
454
- );
440
+ rec.log (velocity_entity_path, rerun::Scalars (joint_velocity));
455
441
}
456
442
}
457
443
@@ -462,14 +448,7 @@ void log_joint_state(
462
448
double joint_effort = msg->effort [i];
463
449
464
450
std::string effort_entity_path = entity_path + " /joint_efforts/" + joint_name;
465
- rec.log (
466
- effort_entity_path,
467
- rerun::Scalars (
468
- rerun::Collection<rerun::components::Scalar>::take_ownership (
469
- {rerun::components::Scalar (joint_effort)}
470
- )
471
- )
472
- );
451
+ rec.log (effort_entity_path, rerun::Scalars (joint_effort));
473
452
}
474
453
}
475
454
}
0 commit comments