| ARX 1.0 The next-generation open source augmented reality toolkit.

Loading...
Searching...
No Matches
Functions
kpmMatching.cpp File Reference
`#include <stdio.h>`
`#include <ARX/AR/ar.h>`
`#include <string>`
`#include <sstream>`
`#include <algorithm>`
`#include <ARX/KPM/kpm.h>`
`#include "kpmPrivate.h"`
`#include "HomographyEst.h"`
`#include "AnnMatch.h"`
`#include "AnnMatch2.h"`
Include dependency graph for kpmMatching.cpp:

## Functions
int | kpmUtilGetPose_binary (ARParamLT *cparamLT, const vision::matches_t &matchData, const std::vector< vision::Point3d< float > > &refDataSet, const std::vector< vision::FeaturePoint > &inputDataSet, float camPose[3][4], float *error)
template<typename T >
std::string | arrayToString (T *v, size_t size)
std::string | arrayToString2 (float pose[3][4])
int | kpmLoadImageDb (KpmHandle *kpmHandle, const char *filename)
int | kpmSetRefDataSet (KpmHandle *kpmHandle, KpmRefDataSet *refDataSet)
| Load a reference data set into the key point matcher for tracking.
int | kpmSetRefDataSetFile (KpmHandle *kpmHandle, const char *filename, const char *ext)
| Loads a reference data set from a file into the KPM tracker.
int | kpmSetRefDataSetFileOld (KpmHandle *kpmHandle, const char *filename, const char *ext)
int | kpmSetMatchingSkipPage (KpmHandle *kpmHandle, int skipPages[], int num)
int | kpmSetMatchingSkipRegion (KpmHandle *kpmHandle, SurfSubRect *skipRegion, int regionNum)
int | kpmMatching (KpmHandle *kpmHandle, ARUint8 *inImageLuma)
| Perform key-point matching on an image.

## Function Documentation

## ◆ arrayToString()

template<typename T >

std::string arrayToString | ( | T * | v,
|  | size_t | size
| ) |  |

## ◆ arrayToString2()

std::string arrayToString2 | ( | float | pose[3][4] | ) |

## ◆ kpmLoadImageDb()

int kpmLoadImageDb | ( | KpmHandle * | kpmHandle,
|  | const char * | filename
| ) |  |

## ◆ kpmMatching()

int kpmMatching | ( | KpmHandle * | kpmHandle,
|  | ARUint8 * | inImageLuma
| ) |  |

Perform key-point matching on an image.

Parameters

  kpmHandle |
  inImageLuma | Source image containing the pixels which will be searched for features. Typically, this is one frame from a video stream. The dimensions of this image must match the values specified at the time of creation of the KPM handle. Luma only.

Returns
  0 if successful, or value <0 in case of error.

See also
  kpmCreateHandle kpmCreateHandle
  kpmCreateHandleHomography kpmCreateHandleHomography

Here is the call graph for this function:

## ◆ kpmSetMatchingSkipPage()

int kpmSetMatchingSkipPage | ( | KpmHandle * | kpmHandle,
|  | int | skipPages[],
|  | int | num
| ) |  |

## ◆ kpmSetMatchingSkipRegion()

int kpmSetMatchingSkipRegion | ( | KpmHandle * | kpmHandle,
|  | SurfSubRect * | skipRegion,
|  | int | regionNum
| ) |  |

## ◆ kpmSetRefDataSet()

int kpmSetRefDataSet | ( | KpmHandle * | kpmHandle,
|  | KpmRefDataSet * | refDataSet
| ) |  |

Load a reference data set into the key point matcher for tracking.

This function takes a reference data set already in memory and makes it the current dataset for key point matching.

Parameters

  kpmHandle | Handle to the current KPM tracker instance, as generated by kpmCreateHandle or kpmCreateHandleHomography.
  refDataSet | The reference data set to load into the KPM handle. The operation takes a copy of the data required from this dataset, thus unless the need for a further load at a later time is required, the dataset can be disposed of by calling kpmDeleteRefDataSet after this operation succeeds.

Returns
  0 if successful, or value <0 in case of error.

See also
  kpmCreateHandle kpmCreateHandle
  kpmCreateHandleHomography kpmCreateHandleHomography
  kpmDeleteRefDataSet kpmDeleteRefDataSet

## ◆ kpmSetRefDataSetFile()

int kpmSetRefDataSetFile | ( | KpmHandle * | kpmHandle,
|  | const char * | filename,
|  | const char * | ext
| ) |  |

Loads a reference data set from a file into the KPM tracker.

This is a convenience method which performs a sequence of kpmLoadRefDataSet, followed by kpmSetRefDataSet and finally kpmDeleteRefDataSet. When tracking from a single reference dataset file, this is the simplest means to start.

Parameters

  kpmHandle | Handle to the current KPM tracker instance, as generated by kpmCreateHandle or kpmCreateHandleHomography.
  filename | Path to the dataset. Either full path, or a relative path if supported by the operating system.
  ext | If non-NULL, a '.' charater and this string will be appended to 'filename'. Often, this parameter is a pointer to the string "fset3".

Returns
  Returns 0 if successful, or value <0 in case of error.

See also
  kpmLoadRefDataSet kpmLoadRefDataSet
  kpmSetRefDataSet kpmSetRefDataSet
  kpmDeleteRefDataSet kpmDeleteRefDataSet

Here is the call graph for this function:

## ◆ kpmSetRefDataSetFileOld()

int kpmSetRefDataSetFileOld | ( | KpmHandle * | kpmHandle,
|  | const char * | filename,
|  | const char * | ext
| ) |  |

Here is the call graph for this function:

## ◆ kpmUtilGetPose_binary()

int kpmUtilGetPose_binary | ( | ARParamLT * | cparamLT,
|  | const vision::matches_t & | matchData,
|  | const std::vector< vision::Point3d< float > > & | refDataSet,
|  | const std::vector< vision::FeaturePoint > & | inputDataSet,
|  | float | camPose[3][4],
|  | float * | error
| ) |  |

Here is the call graph for this function: