Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

VL Namespace Reference

VisionLab namespace. More...

Namespaces

namespace  Detail

Classes

struct  Exception
 Generic exception. More...
struct  PgmBuffer
 PGM buffer descriptor. More...
class  Sift
 SIFT filter. More...

Typedefs

typedef float pixel_t
 Pixel data type.
typedef VL_FASTFLOAT float_t
 Floating point data type.
typedef float float32_t
 32-bit floating data type
typedef double float64_t
 64-bit floating data type
typedef int int32_t
 32-bit integer data type
typedef int uint32_t
 64-bit integer data type
typedef char unsigned uint8_t
 8-bit unsigned integer data type

Functions

PGM input/output

std::ostream & insertPgm (std::ostream &os, pixel_t const *im, int width, int height)
 Insert PGM file into stream.
void createPgmBufferFromArray (int w, int h, pixel_t *d, PgmBuffer &buffer)
std::istream & extractPgm (std::istream &in, PgmBuffer &buffer)
 Extract PGM file from stream.
Fast math

We provide approximate mathematical functions. These are usually rather faster than the corresponding standard library functions.

float fast_resqrt (float x)
 Fast resqrt.
double fast_resqrt (double x)
 Fast resqrt.
float_t fast_expn (VL::float_t x)
 Fast @ exp(-x).
float_t fast_abs (VL::float_t x)
 Fast abs(x).
float_t fast_mod_2pi (VL::float_t x)
 Fast mod(x,2pi).
float_t fast_atan2 (VL::float_t y, VL::float_t x)
 Fast atan2.
float_t fast_sqrt (VL::float_t x)
 Fast sqrt.
int32_t fast_floor (VL::float_t x)
 Fast (int) floor(x).

Detailed Description

VisionLab namespace.


Typedef Documentation

32-bit floating data type

Definition at line 81 of file sift.hpp.

typedef double VL::float64_t

64-bit floating data type

Definition at line 84 of file sift.hpp.

typedef VL_FASTFLOAT VL::float_t

Floating point data type.

Although floats are precise enough for this applicatgion, on Intel based architecture using doubles for floating point computations turns out to be much faster.

Definition at line 78 of file sift.hpp.

typedef int VL::int32_t

32-bit integer data type

Definition at line 87 of file sift.hpp.

typedef float VL::pixel_t

Pixel data type.

Definition at line 70 of file sift.hpp.

typedef int VL::uint32_t

64-bit integer data type

32-bit unsigned integer data type

Definition at line 93 of file sift.hpp.

typedef char unsigned VL::uint8_t

8-bit unsigned integer data type

Definition at line 96 of file sift.hpp.


Function Documentation

void VL::createPgmBufferFromArray ( int  w,
int  h,
pixel_t *  d,
PgmBuffer &  buffer 
)

Start of code added by Xinghao Pan on 14 Apr, 2008

createPgmBufferFromArray added by Xinghao Pan on 14 Apr, 2008

Referenced by siftdriver().

std::istream & VL::extractPgm ( std::istream &  in,
PgmBuffer &  buffer 
)

Extract PGM file from stream.

End of code added by Xinghao Pan on 14 Apr, 2008 The function extracts from the stream in a grayscale image encoded as a PGM file. The function fills the structure buffer, containing the image dimensions and a pointer to the image data.

The image data is an array of floats and is owned by the caller, which should erase it as in

   delete [] buffer.data.

When the function encouters an error it throws a generic instance of VL::Exception.

Parameters:
in input stream.
buffer buffer descriptor to be filled.
Returns:
the stream in.

Referenced by siftdriver().

VL::float_t VL::fast_abs ( VL::float_t  x  ) 

Fast abs(x).

Parameters:
x argument.
Returns:
abs(x)

Definition at line 282 of file sift.ipp.

Referenced by VL::Sift::computeKeypointDescriptor(), VL::Sift::detectKeypoints(), and fast_atan2().

VL::float_t VL::fast_atan2 ( VL::float_t  y,
VL::float_t  x 
)

Fast atan2.

Parameters:
x argument.
y argument.
Returns:
Approximation of atan2(x).

Definition at line 298 of file sift.ipp.

Referenced by VL::Sift::prepareGrad().

VL::float_t VL::fast_expn ( VL::float_t  x  ) 

Fast @ exp(-x).

The argument must be in the range 0-25.0 (bigger arguments may be truncated to zero).

Parameters:
x argument.
Returns:
exp(-x)

Definition at line 217 of file sift.ipp.

Referenced by VL::Sift::computeKeypointDescriptor(), and VL::Sift::computeKeypointOrientations().

int32_t VL::fast_floor ( VL::float_t  x  ) 

Fast (int) floor(x).

Parameters:
x argument.
Returns:
float(x)

Definition at line 266 of file sift.ipp.

Referenced by VL::Sift::computeKeypointDescriptor(), fast_expn(), and VL::Sift::getKeypoint().

VL::float_t VL::fast_mod_2pi ( VL::float_t  x  ) 

Fast mod(x,2pi).

The function quickly computes the value mod(x,2pi).

Remarks:
The computation is fast only for arguments x which are small in modulus.
For negative arguments, the semantic of the function is not equivalent to the standard library fmod function.
Parameters:
x function argument.
Returns:
mod(x,2pi)

Definition at line 247 of file sift.ipp.

Referenced by VL::Sift::computeKeypointDescriptor(), and VL::Sift::prepareGrad().

double VL::fast_resqrt ( double  x  ) 

Fast resqrt.

Parameters:
x argument.
Returns:
Approximation to resqrt(x).

Definition at line 375 of file sift.ipp.

float VL::fast_resqrt ( float  x  ) 

Fast resqrt.

Parameters:
x argument.
Returns:
Approximation to resqrt(x).

Definition at line 349 of file sift.ipp.

Referenced by fast_sqrt().

VL::float_t VL::fast_sqrt ( VL::float_t  x  ) 

Fast sqrt.

Parameters:
x argument.
Returns:
Approximation to sqrt(x).

Definition at line 400 of file sift.ipp.

Referenced by VL::Detail::normalize_histogram(), and VL::Sift::prepareGrad().

std::ostream & VL::insertPgm ( std::ostream &  os,
pixel_t const *  im,
int  width,
int  height 
)

Insert PGM file into stream.

The function iserts into the stream os the grayscale image im encoded as a PGM file. The immage is assumed to be normalized in the range 0.0 - 1.0.

Parameters:
os output stream.
im pointer to image data.
width image width.
height image height.
Returns:
the stream os.

Referenced by siftdriver().


Tekkotsu v5.1CVS
Generated Mon May 9 04:59:26 2016 by Doxygen 1.6.3