package config

import (
	"cicv-data-closedloop/pjisuv_msgs"
	"cicv-data-closedloop/pjisuv_param"
	"github.com/bluenviron/goroslib/v2/pkg/msgs/geometry_msgs"
	"github.com/bluenviron/goroslib/v2/pkg/msgs/nav_msgs"
	"github.com/bluenviron/goroslib/v2/pkg/msgs/sensor_msgs"
	"github.com/bluenviron/goroslib/v2/pkg/msgs/tf2_msgs"
	"github.com/bluenviron/goroslib/v2/pkg/msgs/visualization_msgs"
	"sync"
)

var (
	LabelMapTriggerId sync.Map
	// 扩展
	TopicOfCicvExtend = "/cicv_extend"
	RuleOfCicvExtend  []func(param pjisuv_param.PjisuvParam) string

	//1
	TopicOfAmrPose = "/amr_pose"
	RuleOfAmrPose  []func(data *visualization_msgs.MarkerArray) string

	//2
	TopicOfBoundingBoxesFast = "/bounding_boxes_fast"
	RuleOfBoundingBoxesFast  []func(data *pjisuv_msgs.BoundingBoxArray) string

	//3
	TopicOfCameraFault = "/camera_fault"
	RuleOfCameraFault  []func(data *pjisuv_msgs.FaultVec) string

	//4
	TopicOfCanData = "/can_data"
	RuleOfCanData  []func(data *pjisuv_msgs.Frame) string

	//5
	TopicOfCh128x1LslidarPointCloud = "/ch128x1/lslidar_point_cloud"
	RuleOfCh128x1LslidarPointCloud  []func(data *sensor_msgs.PointCloud2) string

	//6
	TopicOfCh64wLLslidarPointCloud = "/ch64w_l/lslidar_point_cloud"
	RuleOfCh64wLLslidarPointCloud  []func(data *sensor_msgs.PointCloud2) string

	//7
	TopicOfCh64wLScan = "/ch64w_l/scan"
	RuleOfCh64wLScan  []func(data *sensor_msgs.LaserScan) string

	//8
	TopicOfCh64wRLslidarPointCloud = "/ch64w_r/lslidar_point_cloud"
	RuleOfCh64wRLslidarPointCloud  []func(data *sensor_msgs.PointCloud2) string

	//9
	TopicOfCh64wRScan = "/ch64w_r/scan"
	RuleOfCh64wRScan  []func(data *sensor_msgs.LaserScan) string

	//10
	TopicOfCicvLidarclusterMovingObjects = "/cicv/lidarcluster_moving_objects"
	RuleOfCicvLidarclusterMovingObjects  []func(data *pjisuv_msgs.PerceptionCicvMovingObjects) string

	//11
	TopicOfCicvAmrTrajectory = "/cicv_amr_trajectory"
	RuleOfCicvAmrTrajectory  []func(data *pjisuv_msgs.Trajectory, param pjisuv_param.PjisuvParam) string

	//12
	TopicOfCicvLocation = "/cicv_location"
	RuleOfCicvLocation  []func(data *pjisuv_msgs.PerceptionLocalization) string

	//13
	TopicOfCloudClusters = "/cloud_clusters"
	RuleOfCloudClusters  []func(data *pjisuv_msgs.AutowareCloudClusterArray) string

	//14
	TopicOfHeartbeatInfo = "/heartbeat_info"
	RuleOfHeartbeatInfo  []func(data *pjisuv_msgs.HeartBeatInfo) string

	//15
	TopicOfLidarPretreatmentCost = "/lidarPretreatment_Cost"
	RuleOfLidarPretreatmentCost  []func(data *geometry_msgs.Vector3Stamped) string

	//16
	TopicOfLidarPretreatmentOdometry = "/lidar_pretreatment/odometry"
	RuleOfLidarPretreatmentOdometry  []func(data *nav_msgs.Odometry) string

	//17
	TopicOfLidarRoi = "/lidar_roi"
	RuleOfLidarRoi  []func(data *geometry_msgs.PolygonStamped) string

	//18
	TopicOfLine1 = "/line_1"
	RuleOfLine1  []func(data *nav_msgs.Path) string

	//19
	TopicOfLine2 = "/line_2"
	RuleOfLine2  []func(data *nav_msgs.Path) string

	//20
	TopicOfMapPolygon = "/map_polygon"
	RuleOfMapPolygon  []func(data *pjisuv_msgs.PolygonStamped) string

	//21
	TopicOfObstacleDisplay = "/obstacle_display"
	RuleOfObstacleDisplay  []func(data *visualization_msgs.MarkerArray) string

	//22
	TopicOfPjControlPub = "/pj_control_pub"
	RuleOfPjControlPub  []func(data *pjisuv_msgs.CommonVehicleCmd) string

	//23
	TopicOfPointsCluster = "/points_cluster"
	RuleOfPointsCluster  []func(data *sensor_msgs.PointCloud2) string

	//24
	TopicOfPointsConcat = "/points_concat"
	RuleOfPointsConcat  []func(data *sensor_msgs.PointCloud2) string

	//25
	TopicOfReferenceDisplay = "/reference_display"
	RuleOfReferenceDisplay  []func(data *nav_msgs.Path) string

	//26
	TopicOfReferenceTrajectory = "/reference_trajectory"
	RuleOfReferenceTrajectory  []func(data *pjisuv_msgs.Trajectory) string

	//27
	TopicOfRoiPoints = "/roi/points"
	RuleOfRoiPoints  []func(data *sensor_msgs.PointCloud2) string

	//28
	TopicOfRoiPolygon = "/roi/polygon"
	RuleOfRoiPolygon  []func(data *nav_msgs.Path) string

	//29
	TopicOfTf = "/tf"
	RuleOfTf  []func(data *tf2_msgs.TFMessage) string

	//30
	TopicOfTpperception = "/tpperception"
	RuleOfTpperception  []func(data *pjisuv_msgs.PerceptionObjects, extendParam pjisuv_param.PjisuvParam) string

	//31
	TopicOfTpperceptionVis = "/tpperception/vis"
	RuleOfTpperceptionVis  []func(data *visualization_msgs.MarkerArray) string

	//32
	TopicOfTprouteplan = "/tprouteplan"
	RuleOfTprouteplan  []func(data *pjisuv_msgs.RoutePlan) string

	//33
	TopicOfTrajectoryDisplay = "/trajectory_display"
	RuleOfTrajectoryDisplay  []func(data *nav_msgs.Path) string

	//34
	TopicOfUngroundCloudpoints = "/unground_cloudpoints"
	RuleOfUngroundCloudpoints  []func(data *sensor_msgs.PointCloud2) string

	//35
	TopicOfCameraImage = "/camera_image"
	RuleOfCameraImage  []func(data *sensor_msgs.Image) string

	//36
	TopicOfDataRead = "/data_read"
	RuleOfDataRead  []func(data *pjisuv_msgs.Retrieval) string

	//37
	TopicOfPjiGps = "/pji_gps"
	RuleOfPjiGps  []func(data *pjisuv_msgs.PerceptionLocalization) string

	//38
	TopicOfFaultInfo = "/fault_info"
	//RuleOfFaultInfo  []func(data *pjisuv_msgs.FaultVec) string

	//39
	TopicOfPjVehicleFdbPub = "/pj_vehicle_fdb_pub"
	RuleOfPjVehicleFdbPub  []func(data *pjisuv_msgs.VehicleFdb, param *pjisuv_param.PjisuvParam) string
)
