This commit is contained in:
Daniel Grimm 2024-04-23 14:34:35 +02:00 committed by Blyron
parent f9a49c50a4
commit 7be2803454
9 changed files with 26 additions and 59 deletions

View File

@ -58,4 +58,4 @@ namespace carla
} // namespace data
} // namespace sensor
} // namespace carla
} // namespace carla

View File

@ -1,4 +1,4 @@
// Copyright (c) 2024 Institut fuer Technik der Informationsverarbeitung (ITIV) at the
// Copyright (c) 2024 Institut fuer Technik der Informationsverarbeitung (ITIV) at the
// Karlsruhe Institute of Technology
//
// This work is licensed under the terms of the MIT license.
@ -8,18 +8,23 @@
#include "carla/sensor/data/V2XEvent.h"
namespace carla {
namespace sensor {
namespace s11n {
namespace carla
{
namespace sensor
{
namespace s11n
{
SharedPtr<SensorData> CAMDataSerializer::Deserialize(RawData &&data) {
return SharedPtr<data::CAMEvent>(new data::CAMEvent(std::move(data)));
}
SharedPtr<SensorData> CAMDataSerializer::Deserialize(RawData &&data)
{
return SharedPtr<data::CAMEvent>(new data::CAMEvent(std::move(data)));
}
SharedPtr<SensorData> CustomV2XDataSerializer::Deserialize(RawData &&data) {
return SharedPtr<data::CustomV2XEvent>(new data::CustomV2XEvent(std::move(data)));
}
SharedPtr<SensorData> CustomV2XDataSerializer::Deserialize(RawData &&data)
{
return SharedPtr<data::CustomV2XEvent>(new data::CustomV2XEvent(std::move(data)));
}
} // namespace s11n
} // namespace sensor
} // namespace carla
} // namespace s11n
} // namespace sensor
} // namespace carla

View File

@ -76,4 +76,4 @@ namespace carla
} // namespace s11n
} // namespace sensor
} // namespace carla
} // namespace carla

View File

@ -477,45 +477,7 @@ std::string GetVehicleRoleString(ITSContainer::VehicleRole_t vehicleRole)
return "Default";
}
}
// boost::python::list GetVehicleExteriorLightList(const ITSContainer::ExteriorLights_t exteriorLights)
// {
// boost::python::list ExteriorLightsList;
// uint8_t light = *exteriorLights.buf;
// if(light & 0x80)
// {
// ExteriorLightsList.append("Low Beam Head Lights On");
// }
// if(light & 0x40)
// {
// ExteriorLightsList.append("High Beam Head Lights On");
// }
// if(light & 0x20)
// {
// ExteriorLightsList.append("Left turn signal on");
// }
// if(light & 0x10)
// {
// ExteriorLightsList.append("Right turn signal on");
// }
// if(light & 0x08)
// {
// ExteriorLightsList.append("Day time running lights on");
// }
// if(light & 0x04)
// {
// ExteriorLightsList.append("Reverse light on");
// }
// if(light & 0x02)
// {
// ExteriorLightsList.append("Fog light on");
// }
// if(light & 0x01)
// {
// ExteriorLightsList.append("Parking Lights on");
// }
// return ExteriorLightsList;
// }
boost::python::list GetPathHistory(const ITSContainer::PathHistory_t pathHistory)
{
@ -542,7 +504,7 @@ boost::python::dict GetBVCLowFrequency(const CAMContainer::BasicVehicleContainer
{
boost::python::dict BVC;
BVC["Vehicle Role"] = GetVehicleRoleString(bvc.vehicleRole);
BVC["Exterior Light"] = bvc.exteriorLights; // GetVehicleExteriorLightList(bvc.exteriorLights);
BVC["Exterior Light"] = bvc.exteriorLights;
if (bvc.pathHistory.NumberOfPathPoint != 0)
{
BVC["Path History"] = GetPathHistory(bvc.pathHistory);

View File

@ -134,4 +134,4 @@ private:
ITSContainer::SpeedValue_t buildSpeedValue(const float vel);
};
};

View File

@ -141,4 +141,4 @@ protected:
void CalculateFSPL_d0();
TArray<FHitResult> HitResult;
};
};

View File

@ -225,4 +225,4 @@ double PathLossModel::MakeVehicleBlockageLoss(double TxHeight, double RxHeight,
float mean = 5.0f + fmax(0.0f, 15.0f * log10(obj_distance)-41.0f);
return mRandomEngine->GetNormalDistribution(mean, 4.0f);
}
}
}

View File

@ -232,4 +232,4 @@ void AV2XSensor::WriteMessageToV2XData(const AV2XSensor::V2XDataList &msg_receiv
{
mV2XData.WriteMessage(elem);
}
}
}

View File

@ -74,4 +74,4 @@ private:
//write
void WriteMessageToV2XData(const V2XDataList &msg_received_power_list);
};
};