1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date        : 2008-11-28
7  * Description : auto colors correction batch tool.
8  *
9  * Copyright (C) 2008-2021 by Gilles Caulier <caulier dot gilles at gmail dot com>
10  *
11  * This program is free software; you can redistribute it
12  * and/or modify it under the terms of the GNU General
13  * Public License as published by the Free Software Foundation;
14  * either version 2, or (at your option)
15  * any later version.
16  *
17  * This program is distributed in the hope that it will be useful,
18  * but WITHOUT ANY WARRANTY; without even the implied warranty of
19  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
20  * GNU General Public License for more details.
21  *
22  * ============================================================ */
23 
24 #ifndef DIGIKAM_BQM_AUTO_CORRECTION_H
25 #define DIGIKAM_BQM_AUTO_CORRECTION_H
26 
27 // Local includes
28 
29 #include "batchtool.h"
30 
31 class QComboBox;
32 
33 using namespace Digikam;
34 
35 namespace DigikamBqmAutoCorrectionPlugin
36 {
37 
38 class AutoCorrection : public BatchTool
39 {
40     Q_OBJECT
41 
42 public:
43 
44     explicit AutoCorrection(QObject* const parent = nullptr);
45     ~AutoCorrection()                                       override;
46 
47     BatchToolSettings defaultSettings()                     override;
48 
49     BatchTool* clone(QObject* const parent = nullptr) const override;
50 
51     void registerSettingsWidget()                           override;
52 
53 private:
54 
55     bool toolOperations()                                   override;
56 
57 private Q_SLOTS:
58 
59     void slotAssignSettings2Widget()                        override;
60     void slotSettingsChanged()                              override;
61 
62 private:
63 
64     enum AutoCorrectionType
65     {
66         AutoLevelsCorrection = 0,
67         NormalizeCorrection,
68         EqualizeCorrection,
69         StretchContrastCorrection,
70         AutoExposureCorrection
71     };
72 
73     QComboBox* m_comboBox;
74 };
75 
76 } // namespace DigikamBqmAutoCorrectionPlugin
77 
78 #endif // DIGIKAM_BQM_AUTO_CORRECTION_H
79