44 #ifndef vpTemplateTracker_hh
45 #define vpTemplateTracker_hh
49 #include <visp3/core/vpConfig.h>
50 #include <visp3/core/vpImageFilter.h>
51 #include <visp3/tt/vpTemplateTrackerHeader.h>
52 #include <visp3/tt/vpTemplateTrackerWarp.h>
53 #include <visp3/tt/vpTemplateTrackerZone.h>
86 #ifndef DOXYGEN_SHOULD_SKIP_THIS
87 vpTemplateTrackerPointSuppMIInv *ptTemplateSupp;
88 vpTemplateTrackerPointSuppMIInv **ptTemplateSuppPyr;
150 : nbLvlPyr(0), l0Pyr(0), pyrInitialised(false), ptTemplate(nullptr), ptTemplatePyr(nullptr), ptTemplateInit(false),
151 templateSize(0), templateSizePyr(nullptr), ptTemplateSelect(nullptr), ptTemplateSelectPyr(nullptr),
152 ptTemplateSelectInit(false), templateSelectSize(0), ptTemplateSupp(nullptr), ptTemplateSuppPyr(nullptr),
153 ptTemplateCompo(nullptr), ptTemplateCompoPyr(nullptr), zoneTracked(nullptr), zoneTrackedPyr(nullptr), pyr_IDes(nullptr), H(),
154 Hdesire(), HdesirePyr(nullptr), HLM(), HLMdesire(), HLMdesirePyr(nullptr), HLMdesireInverse(),
155 HLMdesireInversePyr(nullptr), G(), gain(0), thresholdGradient(0), costFunctionVerification(false), blur(false),
156 useBrent(false), nbIterBrent(0), taillef(0), fgG(nullptr), fgdG(nullptr), ratioPixelIn(0), mod_i(0), mod_j(0),
157 nbParam(), lambdaDep(0), iterationMax(0), iterationGlobale(0), diverge(false), nbIteration(0),
158 useCompositionnal(false), useInverse(false), Warp(nullptr), p(), dp(), X1(), X2(), dW(), BI(), dIx(), dIy(),
188 void initFromPoints(
const vpImage<unsigned char> &I,
const std::vector<vpImagePoint> &v_ip,
bool delaunay =
false);
196 void setGaussianFilterSize(
unsigned int new_taill);
219 iterationGlobale = 0;
230 void setPyramidal(
unsigned int nlevels = 2,
unsigned int level_to_stop = 1)
233 l0Pyr = level_to_stop;
234 if (l0Pyr >= nlevels) {
235 std::cout <<
"Warning: level_to_stop: " << level_to_stop <<
" higher than level_to_start: " << nlevels - 1
236 <<
" (nlevels-1)" << std::endl;
237 std::cout <<
"Level to stop put to: " << nlevels - 1 << std::endl;
272 #if defined(VISP_BUILD_DEPRECATED_FUNCTIONS)
282 VP_DEPRECATED
void setThresholdRMS(
double threshold) { (void)threshold; }
295 virtual void initPyramidal(
unsigned int nbLvl,
unsigned int l0);
Implementation of column vector and the associated operations.
Class to define RGB colors available for display functionalities.
static const vpColor green
static void filter(const vpImage< ImageType > &I, vpImage< FilterType > &If, const vpArray2D< FilterType > &M, bool convolve=false, const vpImage< bool > *p_mask=nullptr)
Implementation of a matrix and operations on matrices.
vpMatrix inverseByLU() const
static void computeHLM(const vpMatrix &H, const double &alpha, vpMatrix &HLM)
void setThresholdGradient(double threshold)
unsigned int getNbIteration() const
void setCostFunctionVerification(bool b)
void setThresholdResidualDifference(double threshold)
vpTemplateTracker()
Default constructor.
vpMatrix HLMdesireInverse
unsigned int templateSelectSize
vpTemplateTrackerPoint ** ptTemplatePyr
virtual void trackNoPyr(const vpImage< unsigned char > &I)=0
unsigned int * templateSizePyr
void setIterationMax(const unsigned int &n)
vpTemplateTrackerZone * zoneTrackedPyr
vpTemplateTrackerZone zoneRef_
bool ** ptTemplateSelectPyr
void setPyramidal(unsigned int nlevels=2, unsigned int level_to_stop=1)
vpImage< unsigned char > * pyr_IDes
std::vector< double > y_pos
unsigned int getNbParam() const
vpMatrix * HLMdesireInversePyr
std::vector< double > x_pos
unsigned int iterationMax
virtual double getCost(const vpImage< unsigned char > &I, const vpColVector &tp)=0
bool costFunctionVerification
vpTemplateTrackerPointCompo ** ptTemplateCompoPyr
void getGaussianBluredImage(const vpImage< unsigned char > &I)
void setp(const vpColVector &tp)
virtual void initHessienDesired(const vpImage< unsigned char > &I)=0
vpTemplateTrackerPoint * ptTemplate
void setNbIterBrent(const unsigned int &b)
vpTemplateTrackerWarp * Warp
vpTemplateTrackerZone getZoneRef() const
double getRatioPixelIn() const
unsigned int iterationGlobale
void setSampling(int sample_i, int sample_j)
bool ptTemplateSelectInit
vpTemplateTrackerWarp * getWarp() const
void setHDes(vpMatrix &tH)
unsigned int templateSize
vpTemplateTrackerPointCompo * ptTemplateCompo
vpTemplateTrackerZone * zoneTracked