Commit 86a1fa0f authored by oscar's avatar oscar

提价yaml文件读取

parent fc57597c
......@@ -20,7 +20,9 @@ void TrackingRos::Init(ros::NodeHandle& nh)
{
YAML::Node config = YAML::LoadFile("7-1.yaml");
auto value = config["TRACKING"]["TRANS"].as< vector<vector<float>> >();
auto cfg = config["TRACKING"];
auto value = cfg["TRANS"].as< vector<vector<float>> >();
m_coordinate.Init(value[0][0], value[0][1], value[0][2], value[0][3], value[1][0], value[1][1]);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment