Files
qt-migration-legatus/qt6-after/qt6-migrated-legatus/Lts/Services/EffectShowManagement/effect_show_mine_area.h
T
torstenandCopilot b774f4035c Qt6 Migration: DDS-Stubs, Logger-Fixes, Export-Header Korrekturen
- NGL_ADD_LIBRARY2: 87 CMakeLists.txt konvertiert für Export-Header Generierung
- 44 Export-Header Include-Pfade korrigiert (_export.h)
- 81 DDS-Stub-Header generiert (*_dtc.h, *_fts.h, *_dts.h, *_ftc.h)
- INGLLogger: Duplikat gelöscht, m_logger Member entfernt, variadische Makros
- Q_FUNC_INFO Redefinition behoben (Qt6 definiert bereits)
- FATAL_LOG Makro hinzugefügt
- InfrastructureManagement DDS-Stubs (ism.hpp, ism_enums.hpp, ism_ftc.h)
- FilterManagement DDS-Stubs (flt_ftc.h, flt_dts.h)
- AreaEffectSimulation DDS-Stubs (aes.hpp, aes_enums.hpp)
- SymbolAppearance Klasse vollständig definiert mit content() Methode
- BuildingComponentFilter Klasse definiert mit Copy-Konstruktor
- Ftc Factory: nullptr Return (abstract class)
- AesFilter Klasse in aes.hpp hinzugefügt
- Dtc Klasse in ppm.hpp mit participantChanged Signal
- AesType Enum: alle 15 At* Werte definiert
- AesEffectState_def: EsReceived hinzugefügt
- DataModification Enum: eAdded/eModified/eRemoved
- function_reply_object.h → core_types.h Include-Pfad (72 Dateien)
- Enum-Class-Streaming Template-Operator in INGLLogger.h
- ism_mounting_point.h: QImage → QtGui/QImage, QGuiApplication/QScreen
- ism_data_plugin_interface.h: QSet Include, Include-Reihenfolge
- QRegExp → QRegularExpression in tpm_js_parser.cpp
- .underlying() Aufrufe zu direktem Enum-Vergleich korrigiert
- Include-Pfade: aes.hpp in symbol_appearance_settings_impl.h und aes_display_filter_impl.h

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
2026-08-19 06:06:24 +02:00

101 lines
3.4 KiB
C++
Executable File

/**
* Exercise object
* $Id$
* $HeadURL$
* $Author$
*/
#pragma once
#include "logger.h"
#include "handler_pdm_data.h"
#include <AreaEffectSimulation/aes_dtc.h>
#include <EffectShowManagement/esm_db.h>
#include <LtsCoordTrans/lts_coord_trans.h>
#include <QPointF>
namespace EffectShowManagement
{
/**
* @brief Creates the Effect Show data from the Area Effect Simulation data for mine areas.
*
* For the Effect Show data to be created see ICD GUEZSB60_ICD-0046C.
* For calculations the mathematical x-axis is mapped to east; the y-axis is mapped to north.
*
* List of features:\n
* (1)The area for the effect show is limited to 300m x 300m in a grid of 50m.\n
* (2)One effect show area is mapped to the middle segment of the segments of the mine area.\n
* (3)The number of volleys is fixed to 18 volleys\n
* (4)The duration of the effect show is set to "duration of mine area" / 10.\n
* (5)The start time of the effect show is calculated as follows:\n
* "start time mine area" + "duration mine area" - "duration of the effect show"\n
* (6)The type of ammunition is determined by the chargeType of the mine area and the
* "tas code indirect" of the Project Data Management.\n
*/
class EffectShowMineArea
{
public:
explicit EffectShowMineArea(const AreaEffectSimulation::MineArea &mineArea);
/**
* @brief Returns the Effect Show.
* @return The Effect Show
*/
Database::EsmEffectShow getEffectShow();
/**
* @brief Updates the following data: startTime, duration, typeOfAmmunition.
* @param[in] data The Effect Show to be updated
* @param[out] data The updated Effect Show
*/
void updateEffectShow(Database::EsmEffectShow &data);
/**
* @brief Returns the segment of the mine area to be used for effect show.
* The middle segment shall be used for the effect show.
* @return Segment of the mine area to be used for the effect show
*/
static const AreaEffectSimulation::MineSegment &getEffectShowSegment(const AreaEffectSimulation::MineArea &mineArea)
{
return mineArea.segments().at(mineArea.segments().size() / 2);
}
private:
/**
* @brief Calculates the center position and the lower left position of the effect area.
*/
void calculatePositions();
/**
* @brief Returns the width of the effect area.
* Width is the length of the mine area segment.
* @return Width of the effect area. The resolution of the value is 50m. (Max: 300m)
*/
int getEffectAreaWidth() const;
/**
* @brief Returns the Depth of the effect area.
* Depth is the width of the mine area segment.
* @return Depth of the effect area. The resolution of the value is 50m. (Max: 300m)
*/
int getEffectAreaDepth() const;
/**
* @brief Turns position p arround position c.
* @param[in] p Point to be rotated
* @param[in] c Center point of rotation
* @param[in] angle Angle of rotation
* @return Depth of the effect area. The resolution of the value is 50m. (Max: 300m)
*/
static LtsCoordTrans::UtmCoordinate rotate(const LtsCoordTrans::UtmCoordinate &p, const LtsCoordTrans::UtmCoordinate &c, double angle);
private:
AreaEffectSimulation::MineArea const m_mineArea;
const AreaEffectSimulation::MineSegment &m_segment;
int m_utmZone;
LtsCoordTrans::UtmCoordinate m_centerPos;
LtsCoordTrans::UtmCoordinate m_lowerLeftPos;
double m_rotation; // math angle [degree]
};
}