![]() |
Perception Tool Kit (PTK) API Guide
|
A map is a aggregate of multiple grid structures storing different types of summary info about the environment, intended to simplify keeping track of all of them together.
Go to the source code of this file.
Data Structures | |
struct | PTK_GridInfo |
Grid information. More... | |
struct | PTK_MapConfig |
Map configuration. More... | |
struct | PTK_Map |
Map definition. More... | |
Macros | |
#define | PTK_MAP_H |
#define | PTK_MAP_MAX_NUM_GRIDS_PER_MAP 32U |
Maximum number of grids per Map - 1. One of the nodes will be used as a NULL node. More... | |
#define | PTK_MAP_OK ((uint32_t)0) |
Error codes. More... | |
#define | PTK_MAP_XCELL_COUNT_INVALID ((uint32_t)-1) |
Invalid X cell count. More... | |
#define | PTK_MAP_YCELL_COUNT_INVALID ((uint32_t)-2) |
Invalid Y cell count. More... | |
#define | PTK_MAP_ZCELL_COUNT_INVALID ((uint32_t)-3) |
Invalid Z cell count. More... | |
#define | PTK_MAP_GRID_ID_INVALID ((uint32_t)-4) |
Invalid grid ID. More... | |
#define | PTK_MAP_GRID_DATA_TYPE_INVALID ((uint32_t)-5) |
Invalid grid data type. More... | |
#define | PTK_MAP_CELL_DATA_SIZE_INVALID ((uint32_t)-6) |
Invalid grid element data size. More... | |
Functions | |
uint32_t | PTK_Map_getSize (const PTK_MapConfig *config) |
Compute how much memory is required to store the complete PTK_Map described by the given configuration. More... | |
PTK_Map * | PTK_Map_init (uint8_t *mem, const PTK_MapConfig *config) |
Initialize an externally allocated piece of memory to be a valid PTK_Map. This also initializes all member PTK_Grids, so no further initialization is required. More... | |
void | PTK_Map_clear (PTK_Map *map) |
This clears all PTK_Grids internal to the map. It has the same result as if PTK_Grid clear were called on each individually. More... | |
uint32_t | PTK_Map_copy (PTK_Map *__restrict dst, const PTK_Map *__restrict src) |
Copy all constituent PTK_Grids from the given source PTK_Map to the destination PTK_Map. They must have the same PTK_MapConfig or an assertion failure is generated. More... | |
uint32_t | PTK_Map_has (const PTK_Map *map, uint32_t id) |
Test if a PTK_Map contains a PTK_Grid with the specified id. More... | |
PTK_Grid * | PTK_Map_get (const PTK_Map *map, uint32_t id) |
Obtain a pointer to the PTK_Grid matching the specified id. More... | |
#define PTK_MAP_H |
#define PTK_MAP_MAX_NUM_GRIDS_PER_MAP 32U |
Maximum number of grids per Map - 1. One of the nodes will be used as a NULL node.