Skip to contents

Find 1D index given n-dimensional indices

Usage

c_sub2ind(dims, indices)

Arguments

dims

Integer dimensions of the array (usually 3d)

indices

Nx3 integer matrix of pixel coordinates

Value

numeric vector of linear indices into the array