VLFeat - Documentation > C API

# VLFeat.org

Documentation> C API

- Main Page
- Related Pages
- Data Structures
- Files

- File List
- Globals

Data Structures
liop.h File Reference

Local Intensity Order Pattern (LIOP) descriptor (Local Intensity Order Pattern (LIOP) descriptor) More...

`#include "generic.h"`

## Data Structures

struct | VlLiopDesc
| LIOP descriptor extractor object. More...

## Functions

Construct and destroy
VlLiopDesc * | vl_liopdesc_new (vl_int numNeighbours, vl_int numSpatialBins, float radius, vl_size sideLength)
| Create a new LIOP object instance. More...
VlLiopDesc * | vl_liopdesc_new_basic (vl_size sideLength)
| Create a new object with default parameters. More...
void | vl_liopdesc_delete (VlLiopDesc *self)
| Delete object instance. More...
Get data and parameters
vl_size | vl_liopdesc_get_dimension (VlLiopDesc const *self)
| Get the dimension of a LIOP descriptor. More...
vl_size | vl_liopdesc_get_num_neighbours (VlLiopDesc const *self)
| Get the number of neighbours. More...
float | vl_liopdesc_get_intensity_threshold (VlLiopDesc const *self)
| Get the intensity threshold. More...
vl_size | vl_liopdesc_get_num_spatial_bins (VlLiopDesc const *self)
| Get the number of spatial bins. More...
double | vl_liopdesc_get_neighbourhood_radius (VlLiopDesc const *self)
| Get the neighbourhood radius. More...
void | vl_liopdesc_set_intensity_threshold (VlLiopDesc *self, float x)
| Set the intensity threshold. More...
Compute LIOP descriptor
void | vl_liopdesc_process (VlLiopDesc *liop, float *desc, float const *patch)
| Compute liop descriptor for a patch. More...

## Detailed Description

Author
  Hana Sarbortova
  Andrea Vedaldi

See also
  Local Intensity Order Pattern (LIOP) descriptor

## Function Documentation

void vl_liopdesc_delete | ( | VlLiopDesc * | self | ) |

Parameters

  self | object instance.

vl_size vl_liopdesc_get_dimension | ( | VlLiopDesc const * | self | ) |

Parameters

  self | object.

Returns
  dimension.

float vl_liopdesc_get_intensity_threshold | ( | VlLiopDesc const * | self | ) |

Parameters

  self | object.

Returns
  intensity threshold.

See also
  liop-weighing

double vl_liopdesc_get_neighbourhood_radius | ( | VlLiopDesc const * | self | ) |

Parameters

  self | object.

Returns
  neighbourhood radius.

vl_size vl_liopdesc_get_num_neighbours | ( | VlLiopDesc const * | self | ) |

Parameters

  self | object.

Returns
  number of neighbours.

vl_size vl_liopdesc_get_num_spatial_bins | ( | VlLiopDesc const * | self | ) |

Parameters

  self | object.

Returns
  number of spatial bins.

VlLiopDesc* vl_liopdesc_new | ( | vl_int | numNeighbours,
|  | vl_int | numSpatialBins,
|  | float | radius,
|  | vl_size | sideLength
| ) |  |

Parameters

  numNeighbours | number of neighbours.
  numSpatialBins | number of bins.
  radius | radius of the cirucal sample neighbourhoods.
  sideLength | width of the input image patch (the patch is square).

Returns
  new object instance.

The value of radius should be at least less than half the sideLength of the patch.

VlLiopDesc* vl_liopdesc_new_basic | ( | vl_size | sideLength | ) |

Parameters

  sideLength | size of the patches to be processed.

Returns
  new object.

See also
  vl_liopdesc_new.

void vl_liopdesc_process | ( | VlLiopDesc * | self,
|  | float * | desc,
|  | float const * | patch
| ) |  |

Parameters

  self | object instance
  desc | descriptor to be computed (output).
  patch | patch to process

Use vl_liopdesc_get_dimension to get the size of the descriptor desc.

void vl_liopdesc_set_intensity_threshold | ( | VlLiopDesc * | self,
|  | float | x
| ) |  |

Parameters

  self | object.
  x | intensity threshold.

If non-negative, the threshold as is is used when comparing intensities. If negative, the absolute value of the specified number is multipled by the maximum intensity difference inside a patch to obtain the threshold.

See also
  liop-weighing