Main Page
Namespaces
Classes
Files
File List
File Members
3rdParty
ARToolKitPlus
include
ARToolKitPlus
Tracker.h
Go to the documentation of this file.
1
/* ========================================================================
2
* PROJECT: ARToolKitPlus
3
* ========================================================================
4
* This work is based on the original ARToolKit developed by
5
* Hirokazu Kato
6
* Mark Billinghurst
7
* HITLab, University of Washington, Seattle
8
* http://www.hitl.washington.edu/artoolkit/
9
*
10
* Copyright of the derived and new portions of this work
11
* (C) 2006 Graz University of Technology
12
*
13
* This framework is free software; you can redistribute it and/or modify
14
* it under the terms of the GNU General Public License as published by
15
* the Free Software Foundation; either version 2 of the License, or
16
* (at your option) any later version.
17
*
18
* This framework is distributed in the hope that it will be useful,
19
* but WITHOUT ANY WARRANTY; without even the implied warranty of
20
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21
* GNU General Public License for more details.
22
*
23
* You should have received a copy of the GNU General Public License
24
* along with this framework; if not, write to the Free Software
25
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
26
*
27
* For further information please contact
28
* Dieter Schmalstieg
29
* <schmalstieg@icg.tu-graz.ac.at>
30
* Graz University of Technology,
31
* Institut for Computer Graphics and Vision,
32
* Inffeldgasse 16a, 8010 Graz, Austria.
33
* ========================================================================
34
** @author Daniel Wagner
35
*
36
* $Id: Tracker.h 172 2006-07-25 14:05:47Z daniel $
37
* @file
38
* ======================================================================== */
39
40
41
#ifndef __ARTOOLKIT_TRACKER_HEADERFILE__
42
#define __ARTOOLKIT_TRACKER_HEADERFILE__
43
44
45
#include <
ARToolKitPlus/ARToolKitPlus.h
>
46
#include <
ARToolKitPlus/ar.h
>
47
#include <
ARToolKitPlus/arMulti.h
>
48
#include <
ARToolKitPlus/Logger.h
>
49
#include <
ARToolKitPlus/extra/Profiler.h
>
50
#include <
ARToolKitPlus/Camera.h
>
51
52
53
namespace
ARToolKitPlus
{
54
55
57
70
class
Tracker
71
{
72
public
:
73
virtual
~Tracker
()
74
{}
75
77
virtual
void
cleanup
() = 0;
78
79
81
84
virtual
bool
setPixelFormat
(
PIXEL_FORMAT
nFormat) = 0;
85
86
88
95
virtual
bool
loadCameraFile
(
const
char
* nCamParamFile,
ARFloat
nNearClip,
ARFloat
nFarClip) = 0;
96
97
99
105
virtual
void
setLoadUndistLUT
(
bool
nSet) = 0;
106
107
109
virtual
void
setLogger
(
ARToolKitPlus::Logger
* nLogger) = 0;
110
111
113
virtual
int
arDetectMarker
(
ARUint8
*dataPtr,
int
thresh
,
ARMarkerInfo
**marker_info,
int
*marker_num) = 0;
114
115
117
virtual
int
arDetectMarkerLite
(
ARUint8
*dataPtr,
int
thresh,
ARMarkerInfo
**marker_info,
int
*marker_num) = 0;
118
119
121
virtual
ARFloat
arMultiGetTransMat
(
ARMarkerInfo
*marker_info,
int
marker_num,
ARMultiMarkerInfoT
*config) = 0;
123
virtual
ARFloat
arGetTransMat
(
ARMarkerInfo
*marker_info,
ARFloat
center[2],
ARFloat
width,
ARFloat
conv[3][4]) = 0;
124
125
virtual
ARFloat
arGetTransMatCont
(
ARMarkerInfo
*marker_info,
ARFloat
prev_conv[3][4],
ARFloat
center[2],
ARFloat
width,
ARFloat
conv[3][4]) = 0;
126
127
// RPP integration -- [t.pintaric]
128
virtual
ARFloat
rppMultiGetTransMat
(
ARMarkerInfo
*marker_info,
int
marker_num,
ARMultiMarkerInfoT
*config) = 0;
129
virtual
ARFloat
rppGetTransMat
(
ARMarkerInfo
*marker_info,
ARFloat
center[2],
ARFloat
width,
ARFloat
conv[3][4]) = 0;
130
131
133
virtual
int
arLoadPatt
(
char
*
filename
) = 0;
134
135
137
virtual
int
arFreePatt
(
int
patno) = 0;
138
140
virtual
int
arMultiFreeConfig
(
ARMultiMarkerInfoT
*config ) = 0;
141
143
virtual
ARMultiMarkerInfoT
*
arMultiReadConfigFile
(
const
char
*filename) = 0;
144
146
149
virtual
void
activateBinaryMarker
(
int
nThreshold) = 0;
150
152
160
virtual
void
setMarkerMode
(
MARKER_MODE
nMarkerMode) = 0;
161
162
164
175
virtual
void
activateVignettingCompensation
(
bool
nEnable,
int
nCorners=0,
int
nLeftRight=0,
int
nTopBottom=0) = 0;
176
177
179
virtual
void
changeCameraSize
(
int
nWidth,
int
nHeight) = 0;
180
181
183
187
virtual
void
setUndistortionMode
(
UNDIST_MODE
nMode) = 0;
188
190
194
virtual
bool
setPoseEstimator
(
POSE_ESTIMATOR
nMethod) = 0;
195
197
203
virtual
void
setBorderWidth
(
ARFloat
nFraction) = 0;
204
205
207
virtual
void
setThreshold
(
int
nValue) = 0;
208
209
211
virtual
int
getThreshold
()
const
= 0;
212
213
215
virtual
void
activateAutoThreshold
(
bool
nEnable) = 0;
216
217
219
virtual
bool
isAutoThresholdActivated
()
const
= 0;
220
221
223
232
virtual
void
setNumAutoThresholdRetries
(
int
nNumRetries) = 0;
233
234
236
241
virtual
void
setImageProcessingMode
(
IMAGE_PROC_MODE
nMode) = 0;
242
243
245
virtual
const
ARFloat
*
getModelViewMatrix
()
const
= 0;
246
247
249
virtual
const
ARFloat
*
getProjectionMatrix
()
const
= 0;
250
251
253
virtual
const
char
*
getDescription
() = 0;
254
255
257
virtual
PIXEL_FORMAT
getPixelFormat
()
const
= 0;
258
259
261
virtual
int
getBitsPerPixel
()
const
= 0;
262
263
265
269
virtual
int
getNumLoadablePatterns
()
const
= 0;
270
271
273
virtual
Camera
*
getCamera
() = 0;
274
275
277
virtual
void
setCamera
(
Camera
* nCamera) = 0;
278
279
281
virtual
void
setCamera
(
Camera
* nCamera,
ARFloat
nNearClip,
ARFloat
nFarClip) = 0;
282
283
285
virtual
ARFloat
calcOpenGLMatrixFromMarker
(
ARMarkerInfo
* nMarkerInfo,
ARFloat
nPatternCenter[2],
ARFloat
nPatternSize,
ARFloat
*nOpenGLMatrix) = 0;
286
287
289
virtual
Profiler
&
getProfiler
() = 0;
290
291
293
virtual
ARFloat
executeSingleMarkerPoseEstimator
(
ARMarkerInfo
*marker_info,
ARFloat
center[2],
ARFloat
width,
ARFloat
conv[3][4]) = 0;
294
296
virtual
ARFloat
executeMultiMarkerPoseEstimator
(
ARMarkerInfo
*marker_info,
int
marker_num,
ARMultiMarkerInfoT
*config) = 0;
297
};
298
299
300
}
// namespace ARToolKitPlus
301
302
303
#endif //__ARTOOLKIT_TRACKER_HEADERFILE__
ARToolKitPlus::Tracker::getThreshold
virtual int getThreshold() const =0
Returns the current threshold value.
ARToolKitPlus::Tracker::arMultiReadConfigFile
virtual ARMultiMarkerInfoT * arMultiReadConfigFile(const char *filename)=0
reads a standard artoolkit multimarker config file
filename
filename
ARToolKitPlus::Tracker::setLoadUndistLUT
virtual void setLoadUndistLUT(bool nSet)=0
Set to true to try loading camera undistortion table from a cache file.
ARToolKitPlus::ARMultiMarkerInfoT
Definition:
arMulti.h:66
ARToolKitPlus::Tracker::arMultiGetTransMat
virtual ARFloat arMultiGetTransMat(ARMarkerInfo *marker_info, int marker_num, ARMultiMarkerInfoT *config)=0
calculates the transformation matrix between camera and the given multi-marker config ...
ARToolKitPlus::Tracker::setBorderWidth
virtual void setBorderWidth(ARFloat nFraction)=0
Sets a new relative border width. ARToolKit's default value is 0.25.
Camera.h
ARToolKitPlus::Tracker::getNumLoadablePatterns
virtual int getNumLoadablePatterns() const =0
Returns the maximum number of patterns that can be loaded.
ARToolKitPlus::Camera
Definition:
Camera.h:50
ARToolKitPlus::Tracker::getProjectionMatrix
virtual const ARFloat * getProjectionMatrix() const =0
Returns an opengl-style projection transformation matrix.
ARToolKitPlus::Tracker::~Tracker
virtual ~Tracker()
Definition:
Tracker.h:73
ARToolKitPlus::Tracker::getDescription
virtual const char * getDescription()=0
Returns a short description with compiled-in settings.
ARToolKitPlus::Tracker::arDetectMarker
virtual int arDetectMarker(ARUint8 *dataPtr, int thresh, ARMarkerInfo **marker_info, int *marker_num)=0
marker detection using tracking history
ARToolKitPlus::Tracker::setPoseEstimator
virtual bool setPoseEstimator(POSE_ESTIMATOR nMethod)=0
Changes the Pose Estimation Algorithm.
ARToolKitPlus::Tracker::activateVignettingCompensation
virtual void activateVignettingCompensation(bool nEnable, int nCorners=0, int nLeftRight=0, int nTopBottom=0)=0
activates the complensation of brightness falloff in the corners of the camera image ...
ar.h
ARToolKitPlus::Tracker::executeSingleMarkerPoseEstimator
virtual ARFloat executeSingleMarkerPoseEstimator(ARMarkerInfo *marker_info, ARFloat center[2], ARFloat width, ARFloat conv[3][4])=0
Calls the pose estimator set with setPoseEstimator() for single marker tracking.
ARToolKitPlus::Tracker::loadCameraFile
virtual bool loadCameraFile(const char *nCamParamFile, ARFloat nNearClip, ARFloat nFarClip)=0
Loads a camera calibration file and stores data internally.
ARToolKitPlus::Tracker::setPixelFormat
virtual bool setPixelFormat(PIXEL_FORMAT nFormat)=0
Sets the pixel format of the camera image.
ARToolKitPlus::Tracker::arMultiFreeConfig
virtual int arMultiFreeConfig(ARMultiMarkerInfoT *config)=0
frees a multimarker config from memory
ARToolKitPlus::Tracker::executeMultiMarkerPoseEstimator
virtual ARFloat executeMultiMarkerPoseEstimator(ARMarkerInfo *marker_info, int marker_num, ARMultiMarkerInfoT *config)=0
Calls the pose estimator set with setPoseEstimator() for multi marker tracking.
ARToolKitPlus::Tracker::arDetectMarkerLite
virtual int arDetectMarkerLite(ARUint8 *dataPtr, int thresh, ARMarkerInfo **marker_info, int *marker_num)=0
marker detection without using tracking history
ARToolKitPlus::Tracker::arGetTransMat
virtual ARFloat arGetTransMat(ARMarkerInfo *marker_info, ARFloat center[2], ARFloat width, ARFloat conv[3][4])=0
calculates the transformation matrix between camera and the given marker
ARToolKitPlus::Profiler
Definition:
Profiler.h:58
ARToolKitPlus::Tracker
Tracker is the vision core of ARToolKit.
Definition:
Tracker.h:70
ARToolKitPlus::UNDIST_MODE
UNDIST_MODE
Definition:
ARToolKitPlus.h:84
ARToolKitPlus::Tracker::cleanup
virtual void cleanup()=0
does final clean up (memory deallocation)
ARToolKitPlus::Tracker::getProfiler
virtual Profiler & getProfiler()=0
Returns the internal profiler object.
ARToolKitPlus::MARKER_MODE
MARKER_MODE
Definition:
ARToolKitPlus.h:110
ARToolKitPlus::ARMarkerInfo
Definition:
ar.h:71
ARToolKitPlus::POSE_ESTIMATOR
POSE_ESTIMATOR
Definition:
ARToolKitPlus.h:117
ARToolKitPlus
This file should only be compiled when using ARToolKitPlus as a DLL.
Definition:
ar.h:60
ARToolKitPlus::Tracker::setLogger
virtual void setLogger(ARToolKitPlus::Logger *nLogger)=0
sets an instance which implements the ARToolKit::Logger interface
ARToolKitPlus::Tracker::setCamera
virtual void setCamera(Camera *nCamera)=0
Sets a new camera without specifying new near and far clip values.
Profiler.h
ARToolKitPlus.h
ARToolKitPlus::Tracker::setUndistortionMode
virtual void setUndistortionMode(UNDIST_MODE nMode)=0
Changes the undistortion mode.
ARToolKitPlus::ARUint8
unsigned char ARUint8
Definition:
ar.h:66
ARToolKitPlus::Tracker::isAutoThresholdActivated
virtual bool isAutoThresholdActivated() const =0
Returns true if automatic threshold calculation is activated.
ARToolKitPlus::Tracker::getPixelFormat
virtual PIXEL_FORMAT getPixelFormat() const =0
Returns the compiled-in pixel format.
ARToolKitPlus::Tracker::calcOpenGLMatrixFromMarker
virtual ARFloat calcOpenGLMatrixFromMarker(ARMarkerInfo *nMarkerInfo, ARFloat nPatternCenter[2], ARFloat nPatternSize, ARFloat *nOpenGLMatrix)=0
Calculates the OpenGL transformation matrix for a specific marker info.
ARToolKitPlus::Tracker::changeCameraSize
virtual void changeCameraSize(int nWidth, int nHeight)=0
changes the resolution of the camera after the camerafile was already loaded
ARToolKitPlus::Tracker::rppMultiGetTransMat
virtual ARFloat rppMultiGetTransMat(ARMarkerInfo *marker_info, int marker_num, ARMultiMarkerInfoT *config)=0
ARToolKitPlus::IMAGE_PROC_MODE
IMAGE_PROC_MODE
Definition:
ARToolKitPlus.h:91
ARToolKitPlus::Tracker::getCamera
virtual Camera * getCamera()=0
Returns the current camera.
Logger.h
ARToolKitPlus::Tracker::setImageProcessingMode
virtual void setImageProcessingMode(IMAGE_PROC_MODE nMode)=0
Sets an image processing mode (half or full resolution)
ARToolKitPlus::Logger
ARToolKit::Logger specifies the interface for a logging application.
Definition:
Logger.h:61
ARToolKitPlus::Tracker::arLoadPatt
virtual int arLoadPatt(char *filename)=0
loads a pattern from a file
ARToolKitPlus::Tracker::setNumAutoThresholdRetries
virtual void setNumAutoThresholdRetries(int nNumRetries)=0
Sets the number of times the threshold is randomized in case no marker was visible (Default: 2) ...
ARToolKitPlus::Tracker::getBitsPerPixel
virtual int getBitsPerPixel() const =0
Returns the number of bits required to store a single pixel.
ARToolKitPlus::Tracker::arFreePatt
virtual int arFreePatt(int patno)=0
frees a pattern from memory
ARFloat
float ARFloat
Definition:
config.h:60
ARToolKitPlus::Tracker::getModelViewMatrix
virtual const ARFloat * getModelViewMatrix() const =0
Returns an opengl-style modelview transformation matrix.
ARToolKitPlus::PIXEL_FORMAT
PIXEL_FORMAT
Definition:
ARToolKitPlus.h:73
ARToolKitPlus::Tracker::arGetTransMatCont
virtual ARFloat arGetTransMatCont(ARMarkerInfo *marker_info, ARFloat prev_conv[3][4], ARFloat center[2], ARFloat width, ARFloat conv[3][4])=0
ARToolKitPlus::Tracker::rppGetTransMat
virtual ARFloat rppGetTransMat(ARMarkerInfo *marker_info, ARFloat center[2], ARFloat width, ARFloat conv[3][4])=0
thresh
int thresh
Definition:
tools/CameraCalib/src/main.cpp:34
ARToolKitPlus::Tracker::activateAutoThreshold
virtual void activateAutoThreshold(bool nEnable)=0
Enables or disables automatic threshold calculation.
arMulti.h
ARToolKitPlus::Tracker::setMarkerMode
virtual void setMarkerMode(MARKER_MODE nMarkerMode)=0
activate the usage of id-based markers rather than template based markers
ARToolKitPlus::Tracker::activateBinaryMarker
virtual void activateBinaryMarker(int nThreshold)=0
activates binary markers
ARToolKitPlus::Tracker::setThreshold
virtual void setThreshold(int nValue)=0
Sets the threshold value that is used for black/white conversion.
tuw_artoolkitplus
Author(s): Markus Bader
autogenerated on Sun Sep 4 2016 03:24:33