Kstars

filter.h
1 /*
2  SPDX-FileCopyrightText: 2009 Prakash Mohan <[email protected]>
3 
4  SPDX-License-Identifier: GPL-2.0-or-later
5 */
6 #pragma once
7 
8 #include "oal/oal.h"
9 
10 #include <QString>
11 
12 /**
13  * @class OAL::Filter
14  *
15  * Information of user filters
16  */
18 {
19  public:
20  Filter(const QString &id, const QString &model, const QString &vendor, const QString &type, const QString &color,
21  double exposure, int offset, bool useAutoFocus, const QString &lockedFilter, int absFocusPosition);
22 
23  QString id() const
24  {
25  return m_Id;
26  }
27  QString name() const
28  {
29  return m_Name;
30  }
31  QString model() const
32  {
33  return m_Model;
34  }
35  QString vendor() const
36  {
37  return m_Vendor;
38  }
39  QString type() const
40  {
41  return m_Type;
42  }
43  QString color() const
44  {
45  return m_Color;
46  }
47 
48  // Additional fields used by Ekos
49  int offset() const
50  {
51  return m_Offset;
52  }
53  void setOffset(int _offset)
54  {
55  m_Offset = _offset;
56  }
57 
58  double exposure() const
59  {
60  return m_Exposure;
61  }
62  void setExposure(double _exposure)
63  {
64  m_Exposure = _exposure;
65  }
66 
67  QString lockedFilter() const
68  {
69  return m_LockedFilter;
70  }
71  void setLockedFilter(const QString &_filter)
72  {
73  m_LockedFilter = _filter;
74  }
75 
76  bool useAutoFocus() const
77  {
78  return m_UseAutoFocus;
79  }
80  void setUseAutoFocus(bool enabled)
81  {
82  m_UseAutoFocus = enabled;
83  }
84 
85  int absoluteFocusPosition()
86  {
87  return m_AbsoluteFocusPosition;
88  }
89  void setAbsoluteFocusPosition(int newAbsFocusPos)
90  {
91  m_AbsoluteFocusPosition = newAbsFocusPos;
92  }
93 
94  private:
95  QString m_Id, m_Model, m_Vendor, m_Type, m_Color, m_Name, m_LockedFilter;
96  int m_Offset { 0 };
97  int m_AbsoluteFocusPosition { 0 };
98  double m_Exposure { 1.0 };
99  bool m_UseAutoFocus { false };
100 };
This file is part of the KDE documentation.
Documentation copyright © 1996-2022 The KDE developers.
Generated on Sat Aug 13 2022 04:01:52 by doxygen 1.8.17 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.