- training_area_telegrams.cpp: Fixed QJsonObject initializer syntax (Qt6 requires {{}} not ({}))
- training_area_telegrams.cpp: Fixed fromJson() methods to access m_* members directly
- training_area_telegrams.cpp: Fixed brace mismatches in multiple toJson() methods
- training_area_telegrams.h: Changed Header struct to public members for consistency
- tx_mixin.cpp: Fixed getEquipmentNumber() template for direct member access
- lts_coordinate.cpp: Added missing #include <iomanip>
- MIGRATION_STATUS.md: Added migration progress tracking document
C++17 constraint enforced due to RTI Connext DDS 7.7.0 incompatibility with C++20+
Build status: BUILD_RTI=OFF successful (0 errors, warnings only)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
68 lines
2.8 KiB
C++
Executable File
68 lines
2.8 KiB
C++
Executable File
|
|
|
|
#pragma once
|
|
|
|
#include <QtCore/QVector>
|
|
#include <QtCore/QRectF>
|
|
#include <memory>
|
|
|
|
namespace InfrastructureManagement
|
|
{
|
|
class MainStructureElement;
|
|
|
|
namespace Interface
|
|
{
|
|
class Dtc;
|
|
}
|
|
}
|
|
|
|
namespace ParticipantManagement
|
|
{
|
|
namespace Interface
|
|
{
|
|
class Dtc;
|
|
}
|
|
}
|
|
|
|
class QLineF;
|
|
class QPointF;
|
|
class QPolygonF;
|
|
|
|
namespace CollateralDamageSimulation
|
|
{
|
|
namespace Calculations
|
|
{
|
|
struct ParticipantProtectionInfo
|
|
{
|
|
QVector<int> withProtection;
|
|
QVector<int> withoutProtection;
|
|
QVector<int> participantsInUnderground;
|
|
};
|
|
|
|
QHash<int, QPolygonF> getBuildingFootprints(const QVector<int> &buildingIds, const std::shared_ptr<InfrastructureManagement::Interface::Dtc> &ismDtc, const QPointF &impactPosition);
|
|
QVector<int> getDirectlyHitBuildings(const QHash<int, QPolygonF> &footprints, const QPointF &impactPosition);
|
|
int getNearestBlockedBuildingId(const QLineF &ray, const QHash<int, QPolygonF> &buildings);
|
|
QPolygonF getBuildingFootprint(int buildingId, const std::shared_ptr<InfrastructureManagement::Interface::Dtc> &ismDtc);
|
|
QVector<QPolygonF> getProtectionAreas(const QHash<int, QPolygonF> &buildingFootprints, double radius, const QPointF &impactPosition);
|
|
bool isPointVisible(const QPointF ¢er, const QPointF &point, const QPolygonF &polygon);
|
|
bool doLinesIntersect(const QPointF &a1, const QPointF &a2, const QPointF &b1, const QPointF &b2);
|
|
void addOuterBounds(QPolygonF &polygon, const QPointF ¢er, double radius);
|
|
QPointF getStartPosForOuterBounds(const QPolygonF &polygon, const QPolygonF &circle);
|
|
QPointF getEndPosForOuterBounds(const QPolygonF &polygon, const QPolygonF &circle);
|
|
QPointF firstIntersection(const QLineF &line, const QPolygonF &circle);
|
|
ParticipantProtectionInfo getParticipantProtectionInfo(const QVector<int> &participantIds,
|
|
const QVector<QPolygonF> &protectionAreas,
|
|
const QVector<int> &undergroundBuildingIds,
|
|
const QVector<int> &directlyHitBuildingIds,
|
|
const QHash<int, QPolygonF> &buildingFootprints,
|
|
const std::shared_ptr<ParticipantManagement::Interface::Dtc> &ppmDtc,
|
|
const std::shared_ptr<InfrastructureManagement::Interface::Dtc> &ismDtc);
|
|
bool isPointInAnyPolygon(const QHash<int, QPolygonF> &polygons, const QPointF &point);
|
|
QVector<QPolygonF> mergePolygons(const QVector<QPolygonF> &geoPolygons);
|
|
QVector<QPolygonF> getScaledPolygons(const QVector<QPolygonF> &polygons, double factor);
|
|
QVector<int> getUndergroundBuildingIds(const QVector<int> &buildingIds, const std::shared_ptr<InfrastructureManagement::Interface::Dtc> &ismDtc);
|
|
QList<QPointF> getGeoRect(const QPointF ¢er, double edgeLength);
|
|
|
|
}
|
|
}
|