navit
0.5.3-trunk
|
Functions | |
struct coord * | coord_get (unsigned char **p) |
struct coord * | coord_new (int x, int y) |
struct coord * | coord_new_from_attrs (struct attr *parent, struct attr **attrs) |
void | coord_destroy (struct coord *c) |
struct coord_rect * | coord_rect_new (struct coord *lu, struct coord *rl) |
void | coord_rect_destroy (struct coord_rect *r) |
int | coord_rect_overlap (struct coord_rect *r1, struct coord_rect *r2) |
int | coord_rect_contains (struct coord_rect *r, struct coord *c) |
void | coord_rect_extend (struct coord_rect *r, struct coord *c) |
int | coord_parse (const char *coord_input, enum projection output_projection, struct coord *result) |
int | pcoord_parse (const char *c_str, enum projection pro, struct pcoord *pc_ret) |
void | coord_print (enum projection pro, struct coord *c, FILE *out) |
void | coord_format (float lat, float lng, enum coord_format fmt, char *buffer, int size) |
Converts a lat/lon into a text formatted text string. More... | |
unsigned int | coord_hash (const void *key) |
int | coord_equal (const void *a, const void *b) |
Navit, a modular navigation system. Copyright (C) 2005-2008 Navit Team
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
void coord_destroy | ( | struct coord * | c | ) |
Referenced by coord_destroy_py().
int coord_equal | ( | const void * | a, |
const void * | b | ||
) |
Referenced by coord_hash_new(), and destination_equal().
void coord_format | ( | float | lat, |
float | lng, | ||
enum coord_format | fmt, | ||
char * | buffer, | ||
int | size | ||
) |
Converts a lat/lon into a text formatted text string.
lat | The latitude (if lat is 360 or greater, the latitude will be omitted) |
lng | The longitude (if lng is 360 or greater, the longitude will be omitted) |
fmt | The format to use.
|
buffer | A buffer large enough to hold the output + a terminating NULL (up to 31 bytes) |
size | The size of the buffer |
References DEGREES_DECIMAL, DEGREES_MINUTES, DEGREES_MINUTES_SECONDS, and lat.
struct coord * coord_get | ( | unsigned char ** | p | ) |
Get a coordinate
p | Pointer to the coordinate |
Referenced by street_name_number_get(), and street_name_numbers_get().
unsigned int coord_hash | ( | const void * | key | ) |
Referenced by coord_hash_new().
struct coord * coord_new | ( | int | x, |
int | y | ||
) |
Referenced by coord_new_from_attrs(), and coord_new_py().
References attr_search(), coord_new(), attr::num, and attr::u.
Referenced by osd_marker_init().
int coord_parse | ( | const char * | coord_input, |
enum projection | output_projection, | ||
struct coord * | result | ||
) |
Parses char
*coord_input and writes back the coordinates to coord
*result, using projection
output_projection. *coord_input may specify its projection at the beginning. The format for *coord_input can be:
*coord_input | String to be parsed |
output_projection | Desired projection of the result |
*result | For returning result |
References c, dbg, coord_geo::lat, lat, coord_geo::lng, lvl_debug, lvl_error, lvl_info, projection_from_name(), projection_mg, projection_none, projection_utm, transform_from_geo(), transform_to_geo(), x, and y.
Referenced by attr_new_from_text(), bookmarks_set_center_from_file(), navit_get_coord(), parse_line(), pcoord_parse(), and pcoord_py().
void coord_print | ( | enum projection | pro, |
struct coord * | c, | ||
FILE * | out | ||
) |
References projection_to_name(), x, and y.
Referenced by bookmarks_write_center_to_file().
int coord_rect_contains | ( | struct coord_rect * | r, |
struct coord * | c | ||
) |
References dbg_assert, coord_rect::lu, coord_rect::rl, x, and y.
Referenced by Backend::get_pois(), NGQPoint::getPOI(), gui_internal_cmd_pois(), and town_get().
void coord_rect_destroy | ( | struct coord_rect * | r | ) |
Referenced by coord_rect_destroy_py().
void coord_rect_extend | ( | struct coord_rect * | r, |
struct coord * | c | ||
) |
References coord_rect::lu, coord_rect::rl, x, and y.
Referenced by binmap_search_get_item(), binmap_search_street_by_place(), gui_internal_cmd2_route_height_profile(), gui_internal_prepare_search_results_map(), item_get_heightline(), map_route_occluded_bbox(), map_selection_contains_item_rect(), navit_zoom_to_route(), route_calc_selection(), and transform_setup_source_rect().
struct coord_rect * coord_rect_new | ( | struct coord * | lu, |
struct coord * | rl | ||
) |
References dbg_assert, coord_rect::lu, coord_rect::rl, x, and y.
Referenced by coord_rect_new_py().
int coord_rect_overlap | ( | struct coord_rect * | r1, |
struct coord_rect * | r2 | ||
) |
References dbg, dbg_assert, coord_rect::lu, lvl_debug, coord_rect::rl, x, and y.
Referenced by block_init(), block_next(), block_next_lin(), gui_internal_cmd2_route_height_profile(), map_download_selection_check(), poly_get(), and selection_contains().
int pcoord_parse | ( | const char * | c_str, |
enum projection | pro, | ||
struct pcoord * | pc_ret | ||
) |
A wrapper for coord_parse that also returns the projection. For parameters see coord_parse.
References coord_parse(), pcoord::pro, x, pcoord::x, y, and pcoord::y.
Referenced by gui_internal_cmd_enter_coord_do(), and pcoord_get_from_message().