1 #ifndef POINT_MATCH_ALGORITHM_H
2 #define POINT_MATCH_ALGORITHM_H
6 #include "PointMatchPixel.h"
7 #include "PointMatchTriplet.h"
16 typedef QList<PointMatchTriplet> PointMatchList;
27 QList<QPoint>
findPoints (
const QList<PointMatchPixel> &samplePointPixels,
28 const QImage &imageProcessed,
30 const Points &pointsExisting);
35 void allocateMemory(
double** array,
36 fftw_complex** arrayPrime,
43 void assembleLocalMaxima(
double* convolution,
44 PointMatchList& listCreated,
51 void computeConvolution(fftw_complex* imagePrime,
52 fftw_complex* samplePrime,
55 double** convolution);
58 void conjugateMatrix(
int width,
60 fftw_complex* matrix);
63 void dumpToGnuplot (
double* convolution,
66 const QString &filename)
const;
69 void loadImage(
const QImage &imageProcessed,
71 const Points &pointsExisting,
75 fftw_complex** imagePrime);
78 void loadSample(
const QList<PointMatchPixel> &samplePointPixels,
82 fftw_complex** samplePrime,
89 void multiplyMatrices(
int width,
98 int optimizeLengthForFft(
int originalLength);
101 void populateImageArray(
const QImage &imageProcessed,
102 int width,
int height,
106 void populateSampleArray(
const QList<PointMatchPixel> &samplePointPixels,
116 void releaseImageArray(
double* array);
117 void releasePhaseArray(fftw_complex* array);
120 void removePixelsNearExistingPoints(
double* image,
123 const Points &pointsExisting,
124 int pointSeparation);
127 void scanImage(
bool* sampleMaskArray,
129 int sampleMaskHeight,
136 PointMatchList* pointsCreated);
141 #endif // POINT_MATCH_ALGORITHM_H
Model for DlgSettingsPointMatch and CmdSettingsPointMatch.
Algorithm returning a list of points that match the specified point.
QList< QPoint > findPoints(const QList< PointMatchPixel > &samplePointPixels, const QImage &imageProcessed, const DocumentModelPointMatch &modelPointMatch, const Points &pointsExisting)
Find points that match the specified sample point pixels. They are sorted by best-to-worst match...
PointMatchAlgorithm(bool isGnuplot)
Single constructor.