|
map.h File Reference
#include <stdint.h>
Go to the source code of this file.
|
Classes |
struct | map_cell_t |
struct | map_t |
Defines |
#define | MAP_WIFI_MAX_LEVELS 8 |
#define | MAP_WXGX(map, i) (map->origin_x + ((i) - map->size_x / 2) * map->scale) |
#define | MAP_WYGY(map, j) (map->origin_y + ((j) - map->size_y / 2) * map->scale) |
#define | MAP_GXWX(map, x) (floor((x - map->origin_x) / map->scale + 0.5) + map->size_x / 2) |
#define | MAP_GYWY(map, y) (floor((y - map->origin_y) / map->scale + 0.5) + map->size_y / 2) |
#define | MAP_VALID(map, i, j) ((i >= 0) && (i < map->size_x) && (j >= 0) && (j < map->size_y)) |
#define | MAP_INDEX(map, i, j) ((i) + (j) * map->size_x) |
Functions |
map_t * | map_alloc (void) |
void | map_free (map_t *map) |
map_cell_t * | map_get_cell (map_t *map, double ox, double oy, double oa) |
int | map_load_occ (map_t *map, const char *filename, double scale, int negate) |
int | map_load_wifi (map_t *map, const char *filename, int index) |
void | map_update_cspace (map_t *map, double max_occ_dist) |
double | map_calc_range (map_t *map, double ox, double oy, double oa, double max_range) |
void | map_draw_occ (map_t *map, struct _rtk_fig_t *fig) |
void | map_draw_cspace (map_t *map, struct _rtk_fig_t *fig) |
void | map_draw_wifi (map_t *map, struct _rtk_fig_t *fig, int index) |
Define Documentation
#define MAP_WIFI_MAX_LEVELS 8
|
|
#define MAP_WXGX |
( |
map, |
|
|
i |
|
) |
(map->origin_x + ((i) - map->size_x / 2) * map->scale)
|
|
#define MAP_WYGY |
( |
map, |
|
|
j |
|
) |
(map->origin_y + ((j) - map->size_y / 2) * map->scale)
|
|
#define MAP_GXWX |
( |
map, |
|
|
x |
|
) |
(floor((x - map->origin_x) / map->scale + 0.5) + map->size_x / 2)
|
|
#define MAP_GYWY |
( |
map, |
|
|
y |
|
) |
(floor((y - map->origin_y) / map->scale + 0.5) + map->size_y / 2)
|
|
#define MAP_VALID |
( |
map, |
|
|
i, |
|
|
j |
|
) |
((i >= 0) && (i < map->size_x) && (j >= 0) && (j < map->size_y))
|
|
#define MAP_INDEX |
( |
map, |
|
|
i, |
|
|
j |
|
) |
((i) + (j) * map->size_x)
|
|
Function Documentation
map_t* map_alloc |
( |
void |
|
) |
|
|
void map_free |
( |
map_t * |
map |
) |
|
|
int map_load_occ |
( |
map_t * |
map, |
|
|
const char * |
filename, |
|
|
double |
scale, |
|
|
int |
negate |
|
) |
|
|
int map_load_wifi |
( |
map_t * |
map, |
|
|
const char * |
filename, |
|
|
int |
index |
|
) |
|
|
void map_update_cspace |
( |
map_t * |
map, |
|
|
double |
max_occ_dist |
|
) |
|
|
double map_calc_range |
( |
map_t * |
map, |
|
|
double |
ox, |
|
|
double |
oy, |
|
|
double |
oa, |
|
|
double |
max_range |
|
) |
|
|
void map_draw_occ |
( |
map_t * |
map, |
|
|
struct _rtk_fig_t * |
fig |
|
) |
|
|
void map_draw_cspace |
( |
map_t * |
map, |
|
|
struct _rtk_fig_t * |
fig |
|
) |
|
|
void map_draw_wifi |
( |
map_t * |
map, |
|
|
struct _rtk_fig_t * |
fig, |
|
|
int |
index |
|
) |
|
|
Generated on Tue May 3 14:15:41 2005 for Player by 1.3.6
|