Skip to content

Commit

Permalink
Not used
Browse files Browse the repository at this point in the history
  • Loading branch information
benemer committed Dec 18, 2024
1 parent 0395784 commit 2f20c0b
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions ros/src/Utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -185,11 +185,6 @@ inline void FillPointCloud2XYZ(const std::vector<Eigen::Vector3d> &points, Point
}
}

inline void FillPointCloud2Timestamp(const std::vector<double> &timestamps, PointCloud2 &msg) {
sensor_msgs::PointCloud2Iterator<double> msg_t(msg, "time");
for (size_t i = 0; i < timestamps.size(); i++, ++msg_t) *msg_t = timestamps[i];
}

inline std::vector<double> GetTimestamps(const PointCloud2::ConstSharedPtr msg) {
auto timestamp_field = GetTimestampField(msg);
if (!timestamp_field.has_value()) return {};
Expand Down Expand Up @@ -228,13 +223,4 @@ inline std::unique_ptr<PointCloud2> EigenToPointCloud2(const std::vector<Eigen::
[&](const auto &point) { return T * point; });
return EigenToPointCloud2(points_t, header);
}

inline std::unique_ptr<PointCloud2> EigenToPointCloud2(const std::vector<Eigen::Vector3d> &points,
const std::vector<double> &timestamps,
const Header &header) {
auto msg = CreatePointCloud2Msg(points.size(), header, true);
FillPointCloud2XYZ(points, *msg);
FillPointCloud2Timestamp(timestamps, *msg);
return msg;
}
} // namespace kiss_icp_ros::utils

0 comments on commit 2f20c0b

Please sign in to comment.