#pragma once

#include <rclcpp/rclcpp.hpp>
#include <sensor_msgs/msg/point_cloud2.hpp>
#include "message_filters/subscriber.h"
#include "message_filters/time_synchronizer.h"
#include "message_filters/sync_policies/approximate_time.hpp"
#include "interfaces/msg/dist_msg.hpp"
using namespace std;
namespace dist_dev{
    
    class DistSub : public rclcpp::Node {
        public:
            DistSub() ;
            vector<int> dist_arr;
	    void pub_msg(const sensor_msgs::msg::PointCloud2& pc,const DistCfg& cfg);
        void pub_msg(const DistCfg& cfg);
        private:
            rclcpp::Publisher<interfaces::msg::DistMsg>::SharedPtr dist_pub;
            std::shared_ptr<interfaces::msg::DistMsg> dist_msg; 
            
    };
}
