Convert world coordinates to grid indices
ij = world2grid(map,xy)
ij = world2grid(map,xy) converts an array of world coordinates, xy, to a [rows cols] array of grid indices, ij.
ij
map
xy
[rows cols]
collapse all
binaryOccupancyMap
Map representation, specified as a binaryOccupancyMap object.
World coordinates, specified as an n-by-2 vertical array of [x y] pairs, where n is the number of world coordinates.
[x y]
Grid indices, specified as an n-by-2 vertical array of [i j] pairs in [rows cols] format, where n is the number of grid positions.
[i j]
binaryOccupancyMap | grid2world
grid2world