DIPlib Documentation - ©1995-2013 Quantitative Imaging Group, Delft University of Technology.

# CoordinateToIndex

Convert coordinate to pixel index

## SYNOPSIS

`#include "dip_coordsindx.h"`

dip_Error dip_CoordinateToIndex ( coordinates, index, stride )

## FUNCTION

This function converts a pixel coordinate to an pixel index which is specific for the image from which `stride` was obtained. `coordinages` and `stride` must have the same number of elements.

## ARGUMENTS

Data type | Name | Description
`dip_IntegerArray` | `coordinates` | Coordinate array
`dip_int *` | `index` | Pointer to pixel index
`dip_IntegerArray` | `stride` | stride array

## SEE ALSO

`IndexToCoordinate`