8#ifndef META_OCEAN_TRACKING_POINT_CORRESPONDENCES_H
9#define META_OCEAN_TRACKING_POINT_CORRESPONDENCES_H
59 inline unsigned int index()
const;
77 explicit inline operator bool()
const;
378inline PointCorrespondences::Correspondence::operator bool()
const
static HomogenousMatrixT4< U > standard2InvertedFlipped(const HomogenousMatrixT4< U > &world_T_camera)
This class implements a distribution array.
Definition SpatialDistribution.h:272
static constexpr Scalar maxValue()
Scalar correspondenceCandidateSqrDistance
Candidate square distance.
Definition PointCorrespondences.h:88
unsigned int correspondenceIndex
Index of the interest point.
Definition PointCorrespondences.h:82
unsigned int index() const
Returns the index of the interest point.
Definition PointCorrespondences.h:363
Correspondence()
Creates an empty correspondence object.
Definition PointCorrespondences.h:350
unsigned int correspondenceCandidateIndex
Candidate index.
Definition PointCorrespondences.h:85
unsigned int candidateIndex() const
Returns the index of the candidate point.
Definition PointCorrespondences.h:368
Scalar candidateSqrDistance() const
Returns the square distance of the correspondence point.
Definition PointCorrespondences.h:373
bool isUniqueAndAccurate(const Scalar uniquenessSqrFactor, const Scalar maxSqrDistance) const
Returns whether this redundant correspondence objects holds a unique and also accurate correspondence...
Definition PointCorrespondences.h:412
unsigned int correspondenceSecondCandidateIndex
Second candidate index.
Definition PointCorrespondences.h:153
Scalar correspondenceSecondCandidateSqrDistance
Second candidate square distance.
Definition PointCorrespondences.h:156
unsigned int secondCandidateIndex()
Returns the index of the second candidate point.
Definition PointCorrespondences.h:397
Scalar secondCandidateSqrDistance()
Returns the square distance of the second candidate point.
Definition PointCorrespondences.h:402
bool isUnique(const Scalar uniquenessSqrFactor) const
Returns whether this redundant correspondence object holds at least one valid correspondence candidat...
Definition PointCorrespondences.h:407
RedundantCorrespondence()
Creates an empty redundant correspondence object.
Definition PointCorrespondences.h:383
This class implements functions determining point correspondences or validates their accuracy.
Definition PointCorrespondences.h:32
std::vector< RedundantCorrespondence > RedundantCorrespondences
Definition of a vector holding redundant correspondence sets.
Definition PointCorrespondences.h:162
static RedundantCorrespondences determineNearestCandidates(const Vector2 *imagePoints, const size_t numberImagePoints, const Vector2 *candidatePoints, const size_t numberCandidatePoints, const unsigned int width, const unsigned int height, const Scalar searchWindowRadius, Indices32 *candidateUseCounter=nullptr)
Determines the nearest candidates for all given image points from an extra set of candidate image poi...
std::vector< Correspondence > Correspondences
Definition of a vector holding correspondence objects.
Definition PointCorrespondences.h:94
static RedundantCorrespondences determineNearestCandidatesIF(const HomogenousMatrix4 &invertedFlippedExtrinsic, const PinholeCamera &pinholeCamera, const Vector2 *imagePoints, const size_t numberImagePoints, const Vector3 *candidatePoints, const size_t numberCandidatePoints, const bool distortImagePoints, const Scalar searchWindowRadius, Indices32 *candidateUseCounter=nullptr)
Determines the nearest candidates for all given image points from a set of candidate object points.
static RedundantCorrespondences determineNearestCandidates(const Vector2 *imagePoints, const size_t numberImagePoints, const Vector2 *candidatePoints, const Line2 *candidateLines, const size_t numberCandidatePoints, const unsigned int width, const unsigned int height, const Scalar searchWindowRadius, const Scalar maximalLineSqrDistance, Indices32 *candidateUseCounter=nullptr)
Determines the nearest candidates for all given image points from a set of candidate image points.
static Indices32 filterValidCorrespondences(const Vector2 *firstPoints, const Vector2 *secondPoints, const size_t numberPoints, const Scalar thresholdFactor)
Finds the valid correspondences of a set of given 2D point correspondences according to the median di...
static unsigned int determineValidCorrespondencesIF(const HomogenousMatrix4 &invertedFlippedExtrinsic, const PinholeCamera &pinholeCamera, const Vector3 *objectPoints, const Vector2 *imagePoints, const size_t correspondences, const bool distortImagePoints, const Scalar sqrPixelError=Scalar(1.5 *1.5), Indices32 *validCorrespondences=nullptr)
Determines valid correspondences for a set of given object and corresponding image points combined wi...
static Indices32 filterValidCorrespondences(const Vectors2 &firstPoints, const Vectors2 &secondPoints, const Indices32 &subsetIndices, const Scalar thresholdFactor)
Finds the valid correspondences of a set of given 2D point correspondences according to the median di...
static RedundantCorrespondences determineNearestCandidates(const Vector2 *imagePoints, const size_t numberImagePoints, const Vector2 *candidatePoints, const Line2 *candidateLines, const size_t numberCandidatePoints, const Scalar searchWindowRadius, const Scalar maximalLineSqrDistance, const Geometry::SpatialDistribution::DistributionArray &distributionCandidatePoints, Indices32 *candidateUseCounter=nullptr)
Determines the nearest candidates for all given image points from a set of candidate image points.
static void removeInvalidCorrespondences(const HomogenousMatrix4 &extrinsic, const PinholeCamera &pinholeCamera, Vectors3 &objectPoints, Vectors2 &imagePoints, const bool distortImagePoints, const Scalar sqrPixelError=Scalar(1.5 *1.5))
Determines valid correspondences in a set of given object and corresponding image points.
Definition PointCorrespondences.h:422
static unsigned int determineValidCorrespondences(const HomogenousMatrix4 &extrinsic, const PinholeCamera &pinholeCamera, const Vector3 *objectPoints, const Vector2 *imagePoints, const size_t correspondences, const bool distortImagePoints, const Scalar sqrPixelError=Scalar(1.5 *1.5), Indices32 *validCorrespondences=nullptr)
Determines valid correspondences for a set of given object and corresponding image points combined wi...
Definition PointCorrespondences.h:417
static void removeInvalidCorrespondencesIF(const HomogenousMatrix4 &invertedFlippedExtrinsic, const PinholeCamera &pinholeCamera, Vectors3 &objectPoints, Vectors2 &imagePoints, const bool distortImagePoints, const Scalar sqrPixelError=Scalar(1.5 *1.5))
Determines valid correspondences in a set of given object and corresponding image points.
static RedundantCorrespondences determineNearestCandidates(const Vector2 *imagePoints, const size_t numberImagePoints, const Vector2 *candidatePoints, const size_t numberCandidatePoints, const Scalar searchWindowRadius, const Geometry::SpatialDistribution::DistributionArray &distributionCandidatePoints, Indices32 *candidateUseCounter=nullptr)
Determines the nearest candidates for all given image points from a set of candidate image points.
static RedundantCorrespondences determineNearestCandidates(const Vector2 *imagePoints, const size_t numberImagePoints, const Vector2 *candidatePoints, const size_t numberCandidatePoints, const Scalar searchWindowRadius, Indices32 *candidateUseCounter=nullptr)
Determines the nearest candidates for all given image points from an extra set of candidate image poi...
unsigned int sqrDistance(const char first, const char second)
Returns the square distance between two values.
Definition base/Utilities.h:1159
std::vector< Index32 > Indices32
Definition of a vector holding 32 bit index values.
Definition Base.h:96
LineT2< Scalar > Line2
Definition of the Line2 object, depending on the OCEAN_MATH_USE_SINGLE_PRECISION either with single o...
Definition Line2.h:28
std::vector< Vector2 > Vectors2
Definition of a vector holding Vector2 objects.
Definition Vector2.h:64
PinholeCameraT< Scalar > PinholeCamera
Definition of an pinhole camera object with Scalar precision.
Definition PinholeCamera.h:39
HomogenousMatrixT4< Scalar > HomogenousMatrix4
Definition of the HomogenousMatrix4 object, depending on the OCEAN_MATH_USE_SINGLE_PRECISION flag eit...
Definition HomogenousMatrix4.h:44
VectorT2< Scalar > Vector2
Definition of a 2D vector.
Definition Vector2.h:28
VectorT3< Scalar > Vector3
Definition of a 3D vector.
Definition Vector3.h:29
std::vector< Vector3 > Vectors3
Definition of a vector holding Vector3 objects.
Definition Vector3.h:65
float Scalar
Definition of a scalar type.
Definition Math.h:129
Namespace of the Tracker library.
The namespace covering the entire Ocean framework.
Definition Accessor.h:15