QTrk
Classes | Macros | Typedefs | Enumerations | Functions
qtrk_c_api.h File Reference
#include "dllmacros.h"

Go to the source code of this file.

Classes

struct  LocalizationJob
 Structure for region of interest metadata. More...
 
struct  LocalizationResult
 Structure for job results. More...
 
struct  QTrkSettings
 Structure for the settings used by the algorithms implemented in QueuedTracker. More...
 
struct  ROIPosition
 Struct used to define the top-left corner position of an ROI within a frame. ROI is [ x .. x+w ; y .. y+h ]. More...
 
struct  QTrkComputedConfig
 Structure for derived settings computed from base settings in QTrkSettings. More...
 

Macros

#define QTrkCUDA_UseList   -3
 
#define QTrkCUDA_UseAll   -2
 
#define QTrkCUDA_UseBest   -1
 

Typedefs

typedef int LocMode_t
 

Enumerations

enum  LocalizeModeEnum {
  LT_OnlyCOM = 0, LT_XCor1D = 1, LT_QI = 2, LT_Gaussian2D = 4,
  LT_ZLUTAlign = 8, LT_LocalizeZ = 16, LT_NormalizeProfile = 64, LT_ClearFirstFourPixels = 128,
  LT_FourierLUT = 256, LT_LocalizeZWeighted = 512, LT_Force32Bit = 0xffffffff
}
 Flags for selecting localization type. More...
 
enum  QTRK_PixelDataType { QTrkU8 = 0, QTrkU16 = 1, QTrkFloat = 2 }
 Flags indicating the data type of image data. More...
 

Functions

CDLL_EXPORT QueuedTracker *DLL_CALLCONV QTrkCreateInstance (QTrkSettings *cfg)
 Create a QueuedTracker instance and return a pointer to it. More...
 
CDLL_EXPORT void DLL_CALLCONV QTrkFreeInstance (QueuedTracker *qtrk)
 Free a QueuedTracker instance. More...
 
CDLL_EXPORT void DLL_CALLCONV QTrkSetLocalizationMode (QueuedTracker *qtrk, LocMode_t locType)
 Select which algorithm is to be used. More...
 
CDLL_EXPORT void DLL_CALLCONV QTrkScheduleLocalization (QueuedTracker *qtrk, void *data, int pitch, QTRK_PixelDataType pdt, const LocalizationJob *jobInfo)
 Add a job to the queue to be processed. A job entails running the required algorithms on a single region of interest. More...
 
CDLL_EXPORT void DLL_CALLCONV QTrkClearResults (QueuedTracker *qtrk)
 
CDLL_EXPORT void DLL_CALLCONV QTrkFlush (QueuedTracker *qtrk)
 
CDLL_EXPORT int DLL_CALLCONV QTrkScheduleFrame (QueuedTracker *qtrk, void *imgptr, int pitch, int width, int height, ROIPosition *positions, int numROI, QTRK_PixelDataType pdt, const LocalizationJob *jobInfo)
 
CDLL_EXPORT void DLL_CALLCONV QTrkSetRadialZLUT (QueuedTracker *qtrk, float *data, int count, int planes, float *zcmp=0)
 
CDLL_EXPORT void DLL_CALLCONV QTrkGetRadialZLUT (QueuedTracker *qtrk, float *dst)
 
CDLL_EXPORT void DLL_CALLCONV QTrkGetRadialZLUTSize (QueuedTracker *qtrk, int *count, int *planes, int *radialsteps)
 
CDLL_EXPORT void DLL_CALLCONV QTrkBuildLUT (QueuedTracker *qtrk, void *data, int pitch, QTRK_PixelDataType pdt, bool imageLUT, int plane)
 
CDLL_EXPORT void DLL_CALLCONV QTrkFinalizeLUT (QueuedTracker *qtrk)
 
CDLL_EXPORT int DLL_CALLCONV QTrkGetResultCount (QueuedTracker *qtrk)
 
CDLL_EXPORT int DLL_CALLCONV QTrkFetchResults (QueuedTracker *qtrk, LocalizationResult *results, int maxResults)
 
CDLL_EXPORT int DLL_CALLCONV QTrkGetQueueLength (QueuedTracker *qtrk, int *maxQueueLen)
 
CDLL_EXPORT bool DLL_CALLCONV QTrkIsIdle (QueuedTracker *qtrk)
 
CDLL_EXPORT void DLL_CALLCONV QTrkGetProfileReport (QueuedTracker *qtrk, char *dst, int maxStrLen)
 
CDLL_EXPORT void DLL_CALLCONV QTrkGetWarnings (QueuedTracker *qtrk, char *dst, int maxStrLen)
 
CDLL_EXPORT void DLL_CALLCONV QTrkGetComputedConfig (QueuedTracker *qtrk, QTrkComputedConfig *cfg)
 

Macro Definition Documentation

§ QTrkCUDA_UseAll

#define QTrkCUDA_UseAll   -2

Definition at line 117 of file qtrk_c_api.h.

§ QTrkCUDA_UseBest

#define QTrkCUDA_UseBest   -1

Definition at line 118 of file qtrk_c_api.h.

§ QTrkCUDA_UseList

#define QTrkCUDA_UseList   -3

Definition at line 116 of file qtrk_c_api.h.

Typedef Documentation

§ LocMode_t

typedef int LocMode_t

Definition at line 30 of file qtrk_c_api.h.

Enumeration Type Documentation

§ LocalizeModeEnum

Flags for selecting localization type.

Enumerator
LT_OnlyCOM 

Use only COM.

LT_XCor1D 

COM+XCor1D.

LT_QI 

COM+QI.

LT_Gaussian2D 

2D Gaussian localization

LT_ZLUTAlign 

Enable ZLUT align.

Quadrant align uses the QI scheme to find an (x,y) position based on the profile saved in the lookup table rather than expected symmetry in the image. It correlates the quadrant profiles from the image with the interpolated profile from the lookup table at a found z position instead of mirroring the quadrants. Doing this iteratively together with finding a z position based on sampling from the new (x,y) position can increase algorithm accuracy at a severe speed cost.

LT_LocalizeZ 

Enable z localization.

LT_NormalizeProfile 

Normalize found radial profiles.

LT_ClearFirstFourPixels 

Ignore the first four pixels of a frame. Some cameras save timestamps rather than image data in the first four pixels.

LT_FourierLUT 

Make a fourier based lookup table.

LT_LocalizeZWeighted 

Do a ZLUT lookup with adjusted weights, for testing purposes.

LT_Force32Bit 

???

Definition at line 6 of file qtrk_c_api.h.

6  {
7  LT_OnlyCOM = 0,
8  LT_XCor1D = 1,
9  LT_QI = 2,
10  LT_Gaussian2D = 4,
11 
19  LT_ZLUTAlign = 8,
20 
21  LT_LocalizeZ = 16,
22  LT_NormalizeProfile = 64,
24  LT_FourierLUT = 256,
25  LT_LocalizeZWeighted = 512,
26 
27  LT_Force32Bit = 0xffffffff
28 };
Ignore the first four pixels of a frame. Some cameras save timestamps rather than image data in the f...
Definition: qtrk_c_api.h:23
COM+XCor1D.
Definition: qtrk_c_api.h:8
Make a fourier based lookup table.
Definition: qtrk_c_api.h:24
Enable z localization.
Definition: qtrk_c_api.h:21
Normalize found radial profiles.
Definition: qtrk_c_api.h:22
COM+QI.
Definition: qtrk_c_api.h:9
2D Gaussian localization
Definition: qtrk_c_api.h:10
Use only COM.
Definition: qtrk_c_api.h:7
Enable ZLUT align.
Definition: qtrk_c_api.h:19
Do a ZLUT lookup with adjusted weights, for testing purposes.
Definition: qtrk_c_api.h:25

§ QTRK_PixelDataType

Flags indicating the data type of image data.

Enumerator
QTrkU8 

8 bit unsigned int

QTrkU16 

16 bit unsigned int

QTrkFloat 

64 bit float

Definition at line 33 of file qtrk_c_api.h.

34 {
35  QTrkU8 = 0,
36  QTrkU16 = 1,
37  QTrkFloat = 2
38 };
64 bit float
Definition: qtrk_c_api.h:37
16 bit unsigned int
Definition: qtrk_c_api.h:36
8 bit unsigned int
Definition: qtrk_c_api.h:35