Function SimOneAPI::GetTrafficLight

Function Documentation

bool SimOneAPI::GetTrafficLight(const char *mainVehicleId, int opendriveLightId, SimOne_Data_TrafficLight *pTrafficLight)

得到仿真场景中的交通灯的真值

Retrieve Ground Truth for Traffic Light Signals in the Simulation Scene

此函数用于获取仿真场景中某个交通灯消息

This function is used to get one of the traffic lights data in simulation scenario.

参数:
  • mainVehicleId -- [in]

    主车的ID

    Id of the main vehicle

  • opendriveLightId -- [in]

    交通灯在opendrive中的ID

    SensorConfigurations data

  • pTrafficLight -- [out]

    交通灯数据

    Traffic light data

返回:

如果成功获取到交通灯数据,则返回true,否则返回false

Returns true if the traffic light data is successfully retrieved, false otherwise