API Documentation
Loading...
Searching...
No Matches
GeoReferenceDialog.h
Go to the documentation of this file.
1#pragma once
2#include "DLLInfo.h"
3#if NDEVR_VIEWPORT && NDEVR_STATION_MODEL
4#include <NDEVR/FactoryOptions.h>
5#include <NDEVR/Camera.h>
6#include <NDEVR/Pointer.h>
7#include <NDEVR/UUID.h>
8#include <NDEVR/Buffer.h>
9#include <QWidget>
10namespace Ui
11{
12 class GeoReferenceUI;
13}
14namespace NDEVR
15{
16 class QTModelManager;
17 class Scene;
18 class CameraView;
19 struct PopupInfo;
20 class GeoReferenceTable;
21 class NDEVR_API GeoReferenceImportOptionsMenu : public QWidget
22 {
23 Q_OBJECT
24 public:
25 GeoReferenceImportOptionsMenu(QTModelManager* manager, const Buffer<UUID>& import_items, bool has_scale, QWidget* parent = nullptr);
26 virtual ~GeoReferenceImportOptionsMenu() {};
27 signals:
28 void doneSignal();
29 protected:
30 QTModelManager* m_manager;
31 Buffer<UUID> m_import_items;
32 bool m_has_scale;
33 };
34 class NDEVR_API GeoReferenceDialog : public QWidget
35 {
36 Q_OBJECT
37 public:
38 GeoReferenceDialog(QWidget* parent = nullptr);
39 void setModelManager(QTModelManager* manager);
40 void setDatasetA(const Buffer<UUID>& dataset, bool set_other_to_inverse = true);
41 void setDatasetB(const Buffer<UUID>& dataset, bool auto_set_reference = true);
42 Scene referenceScene(uint01 scene) const;
43 void clearAll();
44 void removeReference(const UUID& id);
45 void removeReference(uint01 reference_index, uint01 station_index);
46 void clearPairStations();
47 Matrix<fltp08> calculateMergeMatrix() const;
48 void applyMatrix(uint01 reference_index, const Matrix<fltp08>& mat);
49 void createReferenceStationScene(uint01 reference_index, const Vertex<3, fltp08>& location);
50 uint04 nextStationReferenceIndex(uint01 reference_index) const;
51 bool hasSiblingStationReferenceIndex(uint01 reference_index, uint01 station_index) const;
52 void setupForCombinedPreview(bool preview_combined);
53 bool hasReferenceStation(const UUID& id) const;
54 public:
55 static void ProcessGeoReferenceImport(FactoryOptions::GeoReferenceProperties behavior, QTModelManager* manager, const Buffer<UUID>& import_items);
56 static void UserPlaceImport(QTModelManager* manager, const Buffer<UUID>& import_items, bool perform_scale);
57 static void UserGeoReference(QTModelManager* manager, const Buffer<UUID>& import_items, PopupInfo info);
58 signals:
59 void finishedSignal(bool accepted);
60 protected slots:
61 void orientationModeChangedSlot();
62 void objectDeletedSlot(const UUID& id);
63 protected:
64 void deleteStations();
65 void deleteStations(uint01 reference_index);
66 void init();
67 protected:
68 QTModelManager* m_manager;
69 Buffer<Vector<2, UUID>> m_stations;
70 mutable Vector<2, UUID> m_station_scene;
71 Vector<2, CameraView*> m_camera_views;
72 Vector<2, DynamicPointer<Camera>> m_cameras;
73 Vector<2, Buffer<UUID>> m_models;
74 GeoReferenceTable* m_table;
75 Matrix<fltp08> m_merge_matrix;
76 bool m_is_preview_applied = false;
77 Ui::GeoReferenceUI* ui;
78 };
79}
80#endif
#define NDEVR_API
Definition DLLInfo.h:67
Definition ACIColor.h:37
uint32_t uint04
-Defines an alias representing a 4 byte, unsigned integer -Can represent exact integer values 0 throu...
Definition BaseValues.hpp:115
Definition FontEditor.h:6