Kstars

opticaltrainsettings.h
1/*
2 SPDX-FileCopyrightText: 2022 Jasem Mutlaq <mutlaqja@ikarustech.com>
3
4 SPDX-License-Identifier: GPL-2.0-or-later
5*/
6
7#pragma once
8
9#include <QJsonArray>
10#include <QObject>
11#include <QVariantMap>
12
13namespace Ekos
14{
15
16/**
17 * @brief The OpticalTrainSettings class
18 *
19 * General-purpose class to encapsulate OpticalTrain-specific settings in the database.
20 *
21 * The settings are stored as QVariant Map. Each element in the array should have the following format.
22 * {
23 * "id1": payload1,
24 * "id2", payload2,
25 * ...
26 * }
27 *
28 * 1. The ID is a unique number from the Settings enum.
29 * 2. The Payload is QVariant.
30 *
31 * @author Jasem Mutlaq
32 * @version 1.0
33 */
35{
37
38 public:
39
40 static OpticalTrainSettings *Instance();
41 static void release();
42
43 // Settings
44 typedef enum
45 {
46 Capture,
47 Focus,
48 Mount,
49 Align,
50 Guide,
51 Observatory,
53 Analyze,
55 } Settings;
56
57 /**
58 * @brief setOpticalTrainID This must be called before calling any settings functions below.
59 * @param id ID of optical train
60 */
61 void setOpticalTrainID(uint32_t id);
62
63 void setOneSetting(Settings id, const QVariant &value);
64 QVariant getOneSetting(Settings id);
65 void initSettings();
66 void setSettings(const QVariantMap &settings);
67 const QVariantMap &getSettings() const
68 {
69 return m_Settings;
70 }
71
72 signals:
73 void updated();
74
75 private:
76
78 static OpticalTrainSettings *m_Instance;
79
80 uint32_t m_TrainID {0};
81 QVariantMap m_Settings;
82};
83
84}
Align class handles plate-solving and polar alignment measurement and correction using astrometry....
Definition align.h:77
Analysis tab for Ekos sessions.
Definition analyze.h:35
Captures single or sequence of images from a CCD.
Definition capture.h:94
Handles acquisition & loading of dark frames and defect map for cameras.
Definition darklibrary.h:52
Supports manual focusing and auto focusing using relative and absolute INDI focusers.
Definition focus.h:54
Performs calibration and autoguiding using an ST4 port or directly via the INDI driver.
Definition guide.h:51
Supports controlling INDI telescope devices including setting/retrieving mount properties,...
Definition mount.h:33
The OpticalTrainSettings class.
void setOpticalTrainID(uint32_t id)
setOpticalTrainID This must be called before calling any settings functions below.
The Ekos scheduler is a simple scheduler class to orchestrate automated multi object observation jobs...
Definition scheduler.h:56
Ekos is an advanced Astrophotography tool for Linux.
Definition align.cpp:83
Q_OBJECTQ_OBJECT
QObject * parent() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:04:45 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.