36#include <visp3/core/vpDisplay.h>
37#include <visp3/core/vpException.h>
38#include <visp3/core/vpHomogeneousMatrix.h>
39#include <visp3/core/vpImageConvert.h>
40#include <visp3/core/vpImageFilter.h>
41#include <visp3/core/vpMatrix.h>
42#include <visp3/core/vpPixelMeterConversion.h>
44#include <visp3/visual_features/vpFeatureLuminance.h>
111 :
vpBasicFeature(f), Z(1), nbr(0), nbc(0), bord(10), pixInfo(NULL), firstTimeIn(0), cam()
130 for (
unsigned int i = 0; i <
dim_s; i++)
227 for (
unsigned int m = 0; m < L.getRows(); m++) {
233 double Zinv = 1 /
pixInfo[m].Z;
238 L[m][2] = -(x * Ix + y * Iy) * Zinv;
239 L[m][3] = -Ix * x * y - (1 + y * y) * Iy;
240 L[m][4] = (1 + x * x) * Ix + Iy * x * y;
241 L[m][5] = Iy * x - Ix * y;
269 for (
unsigned int i = 0; i <
dim_s; i++) {
270 e[i] =
s[i] - s_star[i];
298 static int firsttime = 0;
300 if (firsttime == 0) {
314 const vpColor & ,
unsigned int )
const
316 static int firsttime = 0;
318 if (firsttime == 0) {
332 const vpColor & ,
unsigned int )
const
334 static int firsttime = 0;
336 if (firsttime == 0) {
class that defines what is a visual feature
vpColVector s
State of the visual feature.
unsigned int nbParameters
Number of parameters needed to compute the interaction matrix.
unsigned int dim_s
Dimension of the visual feature.
Generic class defining intrinsic camera parameters.
Implementation of column vector and the associated operations.
void resize(unsigned int i, bool flagNullify=true)
Class to define RGB colors available for display functionalities.
error that can be emitted by ViSP classes.
@ dimensionError
Bad dimension.
Class that defines the image luminance visual feature.
unsigned int nbr
Number of rows.
void setCameraParameters(vpCameraParameters &_cam)
vpColVector error(const vpBasicFeature &s_star, unsigned int select=FEATURE_ALL)
vpLuminance * pixInfo
Store the image (as a vector with intensity and gradient I, Ix, Iy)
void display(const vpCameraParameters &cam, const vpImage< unsigned char > &I, const vpColor &color=vpColor::green, unsigned int thickness=1) const
unsigned int nbc
Number of column.
unsigned int bord
Border size.
virtual ~vpFeatureLuminance()
Destructor.
vpFeatureLuminance & operator=(const vpFeatureLuminance &f)
void buildFrom(vpImage< unsigned char > &I)
vpMatrix interaction(unsigned int select=FEATURE_ALL)
vpFeatureLuminance * duplicate() const
void print(unsigned int select=FEATURE_ALL) const
static double derivativeFilterY(const vpImage< T > &I, unsigned int r, unsigned int c)
static double derivativeFilterX(const vpImage< T > &I, unsigned int r, unsigned int c)
Definition of the vpImage class member functions.
Implementation of a matrix and operations on matrices.
static void convertPoint(const vpCameraParameters &cam, const double &u, const double &v, double &x, double &y)