digiKam
recognitionworker.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2010-09-03
7  * Description : Integrated, multithread face detection / recognition
8  *
9  * Copyright (C) 2010-2011 by Marcel Wiesweg <marcel dot wiesweg at gmx dot de>
10  * Copyright (C) 2012-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option)
16  * any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  * GNU General Public License for more details.
22  *
23  * ============================================================ */
24 
25 #ifndef DIGIKAM_RECOGNITION_WORKER_H
26 #define DIGIKAM_RECOGNITION_WORKER_H
27 
28 // Local includes
29 
30 #include "facepipeline_p.h"
31 #include "faceitemretriever.h"
32 
33 namespace Digikam
34 {
35 
36 class Q_DECL_HIDDEN RecognitionWorker : public WorkerObject
37 {
38  Q_OBJECT
39 
40 public:
41 
42  explicit RecognitionWorker(FacePipeline::Private* const dd);
43  ~RecognitionWorker() override;
44 
45 public Q_SLOTS:
46 
47  void process(FacePipelineExtendedPackage::Ptr package);
48  void setThreshold(double threshold, bool);
49 
50  // TODO: add set K-Nearest method
51 
52 protected:
53 
54  void aboutToDeactivate() override;
55 
56 Q_SIGNALS:
57 
59 
60 protected:
61 
65 
66 private:
67 
68  // Disable
69  RecognitionWorker(const RecognitionWorker&) = delete;
70  RecognitionWorker& operator=(const RecognitionWorker&) = delete;
71 };
72 
73 } // namespace Digikam
74 
75 #endif // DIGIKAM_RECOGNITION_WORKER_H
Definition: faceitemretriever.h:35
QExplicitlySharedDataPointer< FacePipelineExtendedPackage > Ptr
Definition: facepipelinepackage.h:168
Definition: facepipeline_p.h:50
Definition: facialrecognition_wrapper.h:47
Definition: recognitionworker.h:37
FacialRecognitionWrapper recognizer
Definition: recognitionworker.h:63
void processed(FacePipelineExtendedPackage::Ptr package)
FacePipeline::Private *const d
Definition: recognitionworker.h:64
FaceItemRetriever imageRetriever
Definition: recognitionworker.h:62
Definition: workerobject.h:45
Definition: datefolderview.cpp:43