Scale Space - Definition. More...
#include "scalespace.h"
#include "mathop.h"
#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>
#include <stdio.h>
Go to the source code of this file.
Classes | |
struct | _VlScaleSpace |
Defines | |
#define | is_valid_geometry(geom) |
Functions | |
void | _vl_scalespace_fill_octave (VlScaleSpace *self, vl_index o) |
static void | _vl_scalespace_start_octave_from_image (VlScaleSpace *self, float const *image, vl_index o) |
static void | _vl_scalespace_start_octave_from_previous_octave (VlScaleSpace *self, vl_index o) |
static void | copy_and_downsample (float *destination, float const *source, vl_size width, vl_size height, vl_size numOctaves) |
static void | copy_and_upsample (float *destination, float const *source, vl_size width, vl_size height) |
void | vl_scalespace_delete (VlScaleSpace *self) |
Delete object. | |
VlScaleSpaceGeometry | vl_scalespace_get_default_geometry (vl_size width, vl_size height) |
Get the default geometry for a given image size. | |
VlScaleSpaceGeometry | vl_scalespace_get_geometry (VlScaleSpace const *self) |
Get the geometry of the scale space. | |
float * | vl_scalespace_get_level (VlScaleSpace *self, vl_index o, vl_index s) |
Get the data of a scale space level. | |
float const * | vl_scalespace_get_level_const (VlScaleSpace const *self, vl_index o, vl_index s) |
Get the data of a scale space level (const) | |
double | vl_scalespace_get_level_sigma (VlScaleSpace const *self, vl_index o, vl_index s) |
Get the scale of a given octave and sublevel. | |
VlScaleSpaceOctaveGeometry | vl_scalespace_get_octave_geometry (VlScaleSpace const *self, vl_index o) |
Get the geometry of an octave of the scalespace. | |
VlScaleSpace * | vl_scalespace_new (vl_size width, vl_size height) |
Create a new scale space object. | |
VlScaleSpace * | vl_scalespace_new_copy (VlScaleSpace *self) |
Create a new copy of the object. | |
VlScaleSpace * | vl_scalespace_new_shallow_copy (VlScaleSpace *self) |
Create a new shallow copy of the object. | |
VlScaleSpace * | vl_scalespace_new_with_geometry (VlScaleSpaceGeometry geom) |
Create a new scale space with the specified geometry. | |
void | vl_scalespace_put_image (VlScaleSpace *self, float const *image) |
Initialise Scale space with new image. | |
vl_bool | vl_scalespacegeometry_is_equal (VlScaleSpaceGeometry a, VlScaleSpaceGeometry b) |
Check scale space geometries for equality. |
Scale Space - Definition.
Definition in file scalespace.c.
#define is_valid_geometry | ( | geom | ) |
(\ geom.firstOctave <= geom.lastOctave && \ geom.octaveResolution >= 1 && \ geom.octaveFirstSubdivision <= geom.octaveLastSubdivision && \ geom.baseScale >= 0.0 && \ geom.nominalScale >= 0.0)
Definition at line 323 of file scalespace.c.
void _vl_scalespace_fill_octave | ( | VlScaleSpace * | self, |
vl_index | o | ||
) |
Definition at line 669 of file scalespace.c.
static void _vl_scalespace_start_octave_from_image | ( | VlScaleSpace * | self, |
float const * | image, | ||
vl_index | o | ||
) | [static] |
------------------------------------------------------------------
Definition at line 700 of file scalespace.c.
static void _vl_scalespace_start_octave_from_previous_octave | ( | VlScaleSpace * | self, |
vl_index | o | ||
) | [static] |
Definition at line 756 of file scalespace.c.
static void copy_and_downsample | ( | float * | destination, |
float const * | source, | ||
vl_size | width, | ||
vl_size | height, | ||
vl_size | numOctaves | ||
) | [static] |
------------------------------------------------------------------
Definition at line 499 of file scalespace.c.
static void copy_and_upsample | ( | float * | destination, |
float const * | source, | ||
vl_size | width, | ||
vl_size | height | ||
) | [static] |
------------------------------------------------------------------
Definition at line 452 of file scalespace.c.
void vl_scalespace_delete | ( | VlScaleSpace * | self | ) |
Delete object.
self | object to delete. |
Definition at line 641 of file scalespace.c.
VlScaleSpaceGeometry vl_scalespace_get_default_geometry | ( | vl_size | width, |
vl_size | height | ||
) |
Get the default geometry for a given image size.
width | image width. |
height | image height. |
Both width and height must be at least one pixel wide.
Definition at line 306 of file scalespace.c.
VlScaleSpaceGeometry vl_scalespace_get_geometry | ( | VlScaleSpace const * | self | ) |
Get the geometry of the scale space.
self | object. |
Definition at line 357 of file scalespace.c.
float* vl_scalespace_get_level | ( | VlScaleSpace * | self, |
vl_index | o, | ||
vl_index | s | ||
) |
Get the data of a scale space level.
self | object. |
o | octave index. |
s | level index. |
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
.
Definition at line 390 of file scalespace.c.
float const* vl_scalespace_get_level_const | ( | VlScaleSpace const * | self, |
vl_index | o, | ||
vl_index | s | ||
) |
Get the data of a scale space level (const)
self | object. |
o | octave index. |
s | level index. |
This function is the same as vl_scalespace_get_level but reutrns a const
pointer to the data.
Definition at line 415 of file scalespace.c.
double vl_scalespace_get_level_sigma | ( | VlScaleSpace const * | self, |
vl_index | o, | ||
vl_index | s | ||
) |
Get the scale of a given octave and sublevel.
------------------------------------------------------------------
self | object. |
o | octave index. |
s | sublevel index. |
The function returns the scale $(o,s)$ as a function of the octave index o and sublevel s.
Definition at line 431 of file scalespace.c.
VlScaleSpaceOctaveGeometry vl_scalespace_get_octave_geometry | ( | VlScaleSpace const * | self, |
vl_index | o | ||
) |
Get the geometry of an octave of the scalespace.
self | object. |
o | octave index. |
Definition at line 369 of file scalespace.c.
VlScaleSpace* vl_scalespace_new | ( | vl_size | width, |
vl_size | height | ||
) |
Create a new scale space object.
width | image width. |
height | image height. |
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.
Definition at line 536 of file scalespace.c.
VlScaleSpace* vl_scalespace_new_copy | ( | VlScaleSpace * | self | ) |
Create a new copy of the object.
self | object to copy from. |
The function returns `NULL` if the copy cannot be made due to an out-of-memory condition.
Definition at line 604 of file scalespace.c.
Create a new shallow copy of the object.
self | object to copy from. |
The function works like vl_scalespace_new_copy() but only allocates the scale space, without actually copying the data.
Definition at line 629 of file scalespace.c.
Create a new scale space with the specified geometry.
------------------------------------------------------------------
geom | scale space geomerty. |
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.
Definition at line 558 of file scalespace.c.
void vl_scalespace_put_image | ( | VlScaleSpace * | self, |
float const * | image | ||
) |
Initialise Scale space with new image.
self | VlScaleSpace object instance. |
image | image to process. |
Compute the data of all the defined octaves and scales of the scale space self.
Definition at line 812 of file scalespace.c.
Check scale space geometries for equality.
a | first geometry. |
b | second geometry. |
Definition at line 337 of file scalespace.c.