- 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>
66 lines
1.5 KiB
C++
Executable File
66 lines
1.5 KiB
C++
Executable File
/**
|
|
* @RDE_HEADER@
|
|
* Class Viewpoint2D
|
|
* $Id$
|
|
* $HeadURL$
|
|
* $Author$
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
// Own
|
|
#include "situation_map_types.h"
|
|
#include <Common/situation_map_logging.h>
|
|
#include <situation_map_export.h>
|
|
|
|
// Qt
|
|
#include <QtCore/QString>
|
|
|
|
class QJsonObject;
|
|
|
|
//----------------------------------------------------------------------------
|
|
namespace SituationMap
|
|
{
|
|
|
|
//----------------------------------------------------------------------------
|
|
// for 2D:
|
|
class SITUATIONMAP_EXPORT Viewpoint2D
|
|
{
|
|
public:
|
|
static constexpr double defaultScale = 999999.9;
|
|
|
|
Viewpoint2D(const QPointF ¢erGeo = QPointF(), double scale = defaultScale, double rotation = 0);
|
|
|
|
bool isNull() const;
|
|
|
|
void resetViewpoint();
|
|
|
|
QPointF centerGeo() const;
|
|
void setCenterGeo(const QPointF ¢erGeo);
|
|
|
|
double scale() const;
|
|
void setScale(double scale);
|
|
|
|
double rotation() const;
|
|
void setRotation(double rotation);
|
|
|
|
static Viewpoint2D read(const QJsonObject &json);
|
|
QJsonObject toJsonObject() const;
|
|
|
|
QString toString() const;
|
|
|
|
protected:
|
|
QPointF m_centerGeo; ///< lon, lat
|
|
double m_scale = defaultScale; // '0' may lead to an ESRI exception. Try to avoid and use another value
|
|
double m_rotation = 0; ///< absoluteAngleDegrees
|
|
};
|
|
//----------------------------------------------------------------------------
|
|
|
|
SITUATIONMAP_EXPORT std::ostream &operator<< (std::ostream &stream,
|
|
const SituationMap::Viewpoint2D &value);
|
|
|
|
|
|
|
|
} // namespace SituationMap
|
|
|