ICF 3.1.1.10
Technical documentation of ICF Libraries
CImageRegionProcessorCompBase.h
Go to the documentation of this file.
1/********************************************************************************
2** This file is part of the ICF Framework. Copyright (C) Witold Gantzke & Kirill Lepskiy
3** ICF Framework may be used under the terms of the LGPL License v. 2.1 by the Free Software Foundation.
4********************************************************************************/
5
6#ifndef iipr_CImageRegionProcessorCompBase_included
7#define iipr_CImageRegionProcessorCompBase_included
8
9
10// ICF includes
13
14
15namespace i2d
16{
17 class IObject2d;
18}
19
20
21namespace iimg
22{
23 class IBitmap;
24}
25
26
27namespace iipr
28{
29
30
35{
36public:
38
39 I_BEGIN_BASE_COMPONENT(CImageRegionProcessorCompBase);
40 I_ASSIGN(m_aoiParamIdAttrPtr, "AoiParamId", "ID of the AOI region in the parameter set (i2d::IObject2d)", true, "AoiParams");
41 I_ASSIGN(m_defaultAoiCompPtr, "DefaultAoi", "Area of interest used if not specified in parameters", false, "DefaultAoi");
42 I_ASSIGN(m_allowEmptyRegionAttrPtr, "AllowEmptyAoi", "If enabled the full image area is used of no AOI was set", true, false);
43 I_END_COMPONENT;
44
45 // reimplemented (iproc::IProcessor)
47 const iprm::IParamsSet* paramsPtr,
48 const istd::IPolymorphic* inputPtr,
49 istd::IChangeable* outputPtr,
50 bool allowAsync = false,
51 iproc::IProgressManager* progressManagerPtr = nullptr) override;
52
53protected:
54 // abstract methods
58 virtual bool ProcessImageRegion(
59 const iimg::IBitmap& inputBitmap,
60 const iprm::IParamsSet* paramsPtr,
61 const i2d::IObject2d* aoiPtr,
62 istd::IChangeable* outputPtr) const = 0;
63
64protected:
65 I_ATTR(QByteArray, m_aoiParamIdAttrPtr);
66 I_REF(i2d::IObject2d, m_defaultAoiCompPtr);
67 I_ATTR(bool, m_allowEmptyRegionAttrPtr);
68};
69
70
71} // namespace iipr
72
73
74#endif // !iipr_CImageRegionProcessorCompBase_included
75
76
Common interface for describing the 2D-objects.
Definition IObject2d.h:30
Definition of single plane bitmap.
Definition IBitmap.h:24
Basic implementation for a image region processor.
virtual bool ProcessImageRegion(const iimg::IBitmap &inputBitmap, const iprm::IParamsSet *paramsPtr, const i2d::IObject2d *aoiPtr, istd::IChangeable *outputPtr) const =0
Process the defined image region.
virtual iproc::CTaskState DoProcessing(const iprm::IParamsSet *paramsPtr, const istd::IPolymorphic *inputPtr, istd::IChangeable *outputPtr, bool allowAsync=false, iproc::IProgressManager *progressManagerPtr=nullptr) override
Set of general parameters.
Definition IParamsSet.h:29
Represent state of asynchronous operation.
Definition CTaskState.h:28
Consume information about progress of some process.
Simple definition macro for a synchronous processor.
Common interface for data model objects, which can be changed.
Definition IChangeable.h:32
Contains the 2D objects.
Definition CAffine2d.h:15
Contains the system indenendent definitions of image and related themes.
Definition CBitmap.h:21
Contains the image processing classes.

© Witold Gantzke and Kirill Lepskiy