ICF 3.1.1.10
Technical documentation of ICF Libraries
CPerspectiveCalibrationSupplierComp.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#pragma once
7
8
9// ICF includes
15
16
17namespace iipr
18{
19
20
22 public iinsp::TSupplierCompWrap<icalib::CPerspectiveCalibration2d>,
23 virtual public i2d::ICalibration2dProvider
24{
25public:
27
28 I_BEGIN_COMPONENT(CPerspectiveCalibrationSupplierComp);
29 I_REGISTER_INTERFACE(i2d::ICalibration2dProvider);
30 I_ASSIGN(m_bitmapProviderCompPtr, "BitmapProvider", "Provide input image", true, "BitmapProvider");
31 I_ASSIGN(m_pointGridExtractorCompPtr, "PointGridExtractor", "Extractor of pointGrid on image", true, "PointGridExtractor");
32 I_ASSIGN(m_pointGridTransformation, "PointGridTransformation", "Provides of 2D transformation of point grid in 2D coortinate space", false, "PointGridTransformation");
33 I_ASSIGN(m_cellSizeParamId, "CellSizeParamsId", "ID of point grid cell size in parameter set (type imeas::INumericValue): cell size in logical units", false, "CellSizeParam");
34 I_ASSIGN(m_defaultCellSizeAttrPtr, "DefaultCellSize", "Default size of single cell (in logical units) if no checkboard parameters specified", true, 10);
35 I_ASSIGN(m_invertXAttrPtr, "InvertX", "Invert x direction", false, false);
36 I_ASSIGN(m_invertYAttrPtr, "InvertY", "Invert y direction", false, false);
37 I_END_COMPONENT;
38
39 // reimplemented (i2d::ICalibration2dProvider)
40 const i2d::ICalibration2d* GetCalibration() const override;
41
42protected:
44
45 // reimplemented (iinsp::TSupplierCompWrap)
46 int ProduceObject(ProductType& result) const override;
47
48private:
49 I_REF(iimg::IBitmapProvider, m_bitmapProviderCompPtr);
50 I_REF(iipr::IImageToFeatureProcessor, m_pointGridExtractorCompPtr);
51 I_REF(i2d::ICalibration2dProvider, m_pointGridTransformation);
52 I_ATTR(QByteArray, m_cellSizeParamId);
53 I_ATTR(double, m_defaultCellSizeAttrPtr);
54 I_ATTR(bool, m_invertXAttrPtr);
55 I_ATTR(bool, m_invertYAttrPtr);
56};
57
58
59} // namespace iipr
60
61
Common interface for an object, which delivers a 2D-calibration.
Definition of single plane bitmap.
Definition IBitmap.h:24
Bitmap supplier allowing to access of produced bitmap.
Standard implementation of interface iinsp::ISupplier with preparation for component implementation.
int ProduceObject(ProductType &result) const override
Produce single object.
const i2d::ICalibration2d * GetCalibration() const override
Get access to transformation object, which transforms a local logical coordinate system to global one...
iinsp::TSupplierCompWrap< icalib::CPerspectiveCalibration2d > BaseClass
bool CalculateCalibration(const iimg::IBitmap &image, icalib::CPerspectiveCalibration2d &result) const
Allow to extract some features from the image.
Contains the image processing classes.

© Witold Gantzke and Kirill Lepskiy