Visual Servoing Platform version 3.7.0
Loading...
Searching...
No Matches
vpMbtXmlGenericParser.h
1/*
2 * ViSP, open source Visual Servoing Platform software.
3 * Copyright (C) 2005 - 2025 by Inria. All rights reserved.
4 *
5 * This software is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
9 * See the file LICENSE.txt at the root directory of this source
10 * distribution for additional information about the GNU GPL.
11 *
12 * For using ViSP with software that can not be combined with the GNU
13 * GPL, please contact Inria about acquiring a ViSP Professional
14 * Edition License.
15 *
16 * See https://visp.inria.fr for more information.
17 *
18 * This software was developed at:
19 * Inria Rennes - Bretagne Atlantique
20 * Campus Universitaire de Beaulieu
21 * 35042 Rennes Cedex
22 * France
23 *
24 * If you have questions regarding the use of this file, please contact
25 * Inria at visp@inria.fr
26 *
27 * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
28 * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
29 *
30 * Description:
31 * Load XML Parameter for Model Based Tracker.
32 */
33
39
40#ifndef _vpMbtXmlGenericParser_h_
41#define _vpMbtXmlGenericParser_h_
42
43#include <visp3/core/vpConfig.h>
44
45#if defined(VISP_HAVE_PUGIXML)
46#include <visp3/core/vpCameraParameters.h>
47#include <visp3/mbt/vpMbtFaceDepthNormal.h>
48#include <visp3/me/vpMe.h>
49
72class VISP_EXPORT vpMbtXmlGenericParser
73{
74public:
86
87public:
88 vpMbtXmlGenericParser(int type = EDGE_PARSER);
89 virtual ~vpMbtXmlGenericParser();
90
91 double getAngleAppear() const;
92 double getAngleDisappear() const;
93
94 void getCameraParameters(vpCameraParameters &cam) const;
95
96 void getEdgeMe(vpMe &ecm) const;
97
98 unsigned int getDepthDenseSamplingStepX() const;
99 unsigned int getDepthDenseSamplingStepY() const;
100
101 vpMbtFaceDepthNormal::vpFeatureEstimationType getDepthNormalFeatureEstimationMethod() const;
102 int getDepthNormalPclPlaneEstimationMethod() const;
103 int getDepthNormalPclPlaneEstimationRansacMaxIter() const;
104 double getDepthNormalPclPlaneEstimationRansacThreshold() const;
105 unsigned int getDepthNormalSamplingStepX() const;
106 unsigned int getDepthNormalSamplingStepY() const;
107
108 double getFarClippingDistance() const;
109 bool getFovClipping() const;
110
111 unsigned int getKltBlockSize() const;
112 double getKltHarrisParam() const;
113 unsigned int getKltMaskBorder() const;
114 unsigned int getKltMaxFeatures() const;
115 double getKltMinDistance() const;
116 unsigned int getKltPyramidLevels() const;
117 double getKltQuality() const;
118 unsigned int getKltWindowSize() const;
119
120 bool getLodState() const;
121 double getLodMinLineLengthThreshold() const;
122 double getLodMinPolygonAreaThreshold() const;
123
124 double getNearClippingDistance() const;
125
126 void getProjectionErrorMe(vpMe &me) const;
127
128 unsigned int getProjectionErrorKernelSize() const;
129
130 bool hasFarClippingDistance() const;
131 bool hasNearClippingDistance() const;
132
133 void parse(const std::string &filename);
134
135 void setAngleAppear(const double &aappear);
136 void setAngleDisappear(const double &adisappear);
137
138 void setCameraParameters(const vpCameraParameters &cam);
139
140 void setDepthDenseSamplingStepX(unsigned int stepX);
141 void setDepthDenseSamplingStepY(unsigned int stepY);
142
143 void setDepthNormalFeatureEstimationMethod(const vpMbtFaceDepthNormal::vpFeatureEstimationType &method);
144 void setDepthNormalPclPlaneEstimationMethod(int method);
145 void setDepthNormalPclPlaneEstimationRansacMaxIter(int maxIter);
146 void setDepthNormalPclPlaneEstimationRansacThreshold(double threshold);
147 void setDepthNormalSamplingStepX(unsigned int stepX);
148 void setDepthNormalSamplingStepY(unsigned int stepY);
149
150 void setEdgeMe(const vpMe &ecm);
151
152 void setFarClippingDistance(const double &fclip);
153
154 void setKltBlockSize(const unsigned int &bs);
155 void setKltHarrisParam(const double &hp);
156 void setKltMaskBorder(const unsigned int &mb);
157 void setKltMaxFeatures(const unsigned int &mF);
158 void setKltMinDistance(const double &mD);
159 void setKltPyramidLevels(const unsigned int &pL);
160 void setKltQuality(const double &q);
161 void setKltWindowSize(const unsigned int &w);
162
163 void setNearClippingDistance(const double &nclip);
164
165 void setProjectionErrorMe(const vpMe &me);
166 void setProjectionErrorKernelSize(const unsigned int &size);
167
168 void setVerbose(bool verbose);
169
170private:
171 vpMbtXmlGenericParser(const vpMbtXmlGenericParser &); // noncopyable
172 vpMbtXmlGenericParser &operator=(const vpMbtXmlGenericParser &); //
173
174 // PIMPL idiom
175 class Impl;
176 Impl *m_impl;
177};
178END_VISP_NAMESPACE
179#endif
180#endif
Generic class defining intrinsic camera parameters.
Parse an Xml file to extract configuration parameters of a mbtConfig object.
vpMbtXmlGenericParser(int type=EDGE_PARSER)
Definition vpMe.h:143