Fill the border of array according to the boundary condition
dip_Error DIP_TPI_FUNC(dip_FillBoundaryArray)( in, out, size, border, boundary )
Set the values of the border pixels of an array. The pixels of out outside the range of the array in are set to a value determined by the boundary condition and the pixel values of in.
Data type | Name | Description |
void * | in | input array |
void * | out | output array |
dip_int | size | size of input array |
dip_int | border | size of the extended borders |
dip_Boundary | boundary | Boundary conditions |
The out array has to be allocated before this function is called, and should at least has the size of (size + 2 * border). Thus, border specifies the length of the border on both sides of the in array. Furthermore, the out pointer should point to that element in the out array that corresponds to the first element in the in array:
<- size -> input: ************************ | in <- border -><- size -><- border -> output: ------------************************------------ | out
The enumerator dip_boundary contains the following constants:
Name | Description |
DIP_BC_SYM_MIRROR | Symmetric mirroring |
DIP_BC_ASYM_MIRROR | Asymmetric mirroring |
DIP_BC_PERIODIC | Periodic copying |
DIP_BC_ASYM_PERIODIC | Asymmetric periodic copying |
DIP_BC_ADD_ZEROS | Extending the image with zeros |
DIP_BC_ADD_MAX_VALUE | Extending the image with +infinity |
DIP_BC_ADD_MIN_VALUE | Extending the image with -infinity |