Documentation>C API
scalespace.h File Reference

Scale Space (Gaussian Scale Space (GSS)) More...

#include "generic.h"
#include "imopv.h"
#include "mathop.h"

Data Structures

struct  _VlScaleSpaceGeometry
 Geometry of a scale space. More...
 
struct  _VlScaleSpaceOctaveGeometry
 Geometry of one octave of a scale space. More...
 

Functions

vl_bool vl_scalespacegeometry_is_equal (VlScaleSpaceGeometry a, VlScaleSpaceGeometry b)
 Check scale space geometries for equality. More...
 
Create and destroy
VlScaleSpaceGeometry vl_scalespace_get_default_geometry (vl_size width, vl_size height)
 Get the default geometry for a given image size. More...
 
VlScaleSpacevl_scalespace_new (vl_size width, vl_size height)
 Create a new scale space object. More...
 
VlScaleSpacevl_scalespace_new_with_geometry (VlScaleSpaceGeometry geom)
 Create a new scale space with the specified geometry. More...
 
VlScaleSpacevl_scalespace_new_copy (VlScaleSpace *src)
 Create a new copy of the object. More...
 
VlScaleSpacevl_scalespace_new_shallow_copy (VlScaleSpace *src)
 Create a new shallow copy of the object. More...
 
void vl_scalespace_delete (VlScaleSpace *self)
 Delete object. More...
 
Process data
void vl_scalespace_put_image (VlScaleSpace *self, float const *image)
 Initialise Scale space with new image. More...
 
Retrieve data and parameters
VlScaleSpaceGeometry vl_scalespace_get_geometry (VlScaleSpace const *self)
 Get the geometry of the scale space. More...
 
VlScaleSpaceOctaveGeometry vl_scalespace_get_octave_geometry (VlScaleSpace const *self, vl_index o)
 Get the geometry of an octave of the scalespace. More...
 
float * vl_scalespace_get_level (VlScaleSpace *self, vl_index o, vl_index s)
 Get the data of a scale space level. More...
 
const float * vl_scalespace_get_level_const (VlScaleSpace const *self, vl_index o, vl_index s)
 Get the data of a scale space level (const) More...
 
double vl_scalespace_get_level_sigma (VlScaleSpace const *self, vl_index o, vl_index s)
 Get the scale of a given octave and sublevel. More...
 

Detailed Description

Author
Andrea Vedaldi
Karel Lenc
Michal Perdoch

Function Documentation

◆ vl_scalespace_delete()

void vl_scalespace_delete ( VlScaleSpace self)
Parameters
selfobject to delete.
See also
vl_scalespace_new()

◆ vl_scalespace_get_default_geometry()

VlScaleSpaceGeometry vl_scalespace_get_default_geometry ( vl_size  width,
vl_size  height 
)
Parameters
widthimage width.
heightimage height.
Returns
the default scale space geometry.

Both width and height must be at least one pixel wide.

◆ vl_scalespace_get_geometry()

VlScaleSpaceGeometry vl_scalespace_get_geometry ( VlScaleSpace const *  self)
Parameters
selfobject.
Returns
the scale space geometry.

◆ vl_scalespace_get_level()

float* vl_scalespace_get_level ( VlScaleSpace self,
vl_index  o,
vl_index  s 
)
Parameters
selfobject.
ooctave index.
slevel index.
Returns
pointer to the data for octave o, level s.

The octave index o must be in the range firstOctave to lastOctave and the scale index s must be in the range octaveFirstSubdivision to octaveLastSubdivision.

◆ vl_scalespace_get_level_const()

const float* vl_scalespace_get_level_const ( VlScaleSpace const *  self,
vl_index  o,
vl_index  s 
)
Parameters
selfobject.
ooctave index.
slevel index.
Returns
pointer to the data for octave o, level s.

This function is the same as vl_scalespace_get_level but reutrns a const pointer to the data.

◆ vl_scalespace_get_level_sigma()

double vl_scalespace_get_level_sigma ( VlScaleSpace const *  self,
vl_index  o,
vl_index  s 
)
Parameters
selfobject.
ooctave index.
ssublevel index.

The function returns the scale \(\sigma(o,s)\) as a function of the octave index o and sublevel s.

◆ vl_scalespace_get_octave_geometry()

VlScaleSpaceOctaveGeometry vl_scalespace_get_octave_geometry ( VlScaleSpace const *  self,
vl_index  o 
)
Parameters
selfobject.
ooctave index.
Returns
the geometry of octave o.

◆ vl_scalespace_new()

VlScaleSpace* vl_scalespace_new ( vl_size  width,
vl_size  height 
)
Parameters
widthimage width.
heightimage height.
Returns
new scale space object.

This function is the same as vl_scalespace_new_with_geometry() but it uses vl_scalespace_get_default_geometry to initialise the geometry of the scale space from the image size.

See also
vl_scalespace_new_with_geometry(), vl_scalespace_delete().

◆ vl_scalespace_new_copy()

VlScaleSpace* vl_scalespace_new_copy ( VlScaleSpace self)
Parameters
selfobject to copy from.

The function returns NULL if the copy cannot be made due to an out-of-memory condition.

◆ vl_scalespace_new_shallow_copy()

VlScaleSpace* vl_scalespace_new_shallow_copy ( VlScaleSpace self)
Parameters
selfobject to copy from.

The function works like vl_scalespace_new_copy() but only allocates the scale space, without actually copying the data.

◆ vl_scalespace_new_with_geometry()

VlScaleSpace* vl_scalespace_new_with_geometry ( VlScaleSpaceGeometry  geom)
Parameters
geomscale space geomerty.
Returns
new scale space object.

If the geometry is not valid (see ::VlScaleSpaceGeometry), the result is unpredictable.

The function returns NULL if it was not possible to allocate the object because of an out-of-memory condition.

See also
::VlScaleSpaceGeometry, vl_scalespace_delete().

◆ vl_scalespace_put_image()

void vl_scalespace_put_image ( VlScaleSpace self,
float const *  image 
)
Parameters
selfVlScaleSpace object instance.
imageimage to process.

Compute the data of all the defined octaves and scales of the scale space self.

◆ vl_scalespacegeometry_is_equal()

vl_bool vl_scalespacegeometry_is_equal ( VlScaleSpaceGeometry  a,
VlScaleSpaceGeometry  b 
)
Parameters
afirst geometry.
bsecond geometry.
Returns
true if equal.