navit
0.5.3-trunk
|
#include "coord.h"
Go to the source code of this file.
Macros | |
#define | TRANSFORM_ERR_BUF_SPACE -1 |
Functions | |
struct transformation * | transform_new (struct pcoord *center, int scale, int yaw) |
int | transform_get_hog (struct transformation *this_) |
void | transform_set_hog (struct transformation *this_, int hog) |
int | transform_get_attr (struct transformation *this_, enum attr_type type, struct attr *attr, struct attr_iter *iter) |
int | transform_set_attr (struct transformation *this_, struct attr *attr) |
int | transformation_get_order_base (struct transformation *this_) |
void | transform_set_order_base (struct transformation *this_, int order_base) |
struct transformation * | transform_dup (struct transformation *t) |
void | transform_to_geo (enum projection pro, const struct coord *c, struct coord_geo *g) |
Transform the coordinates of a geographical point from a coord representation to a geographical (lat, long) representation. More... | |
void | transform_from_geo (enum projection pro, const struct coord_geo *g, struct coord *c) |
Transform the coordinates of a geographical point from a geographical (lat, long) representation to a coord representation. More... | |
void | transform_from_to_count (struct coord *cfrom, enum projection from, struct coord *cto, enum projection to, int count) |
void | transform_from_to (struct coord *cfrom, enum projection from, struct coord *cto, enum projection to) |
void | transform_geo_to_cart (struct coord_geo *geo, navit_float a, navit_float b, struct coord_geo_cart *cart) |
Transforms geodetic to Cartesian coordinates. More... | |
void | transform_cart_to_geo (struct coord_geo_cart *cart, navit_float a, navit_float b, struct coord_geo *geo) |
Transforms Cartesian to geodetic coordinates. More... | |
void | transform_utm_to_geo (const double UTMEasting, const double UTMNorthing, int ZoneNumber, int NorthernHemisphere, struct coord_geo *geo) |
Converts UTM coords to lat/long. More... | |
void | transform_datum (struct coord_geo *from, enum map_datum from_datum, struct coord_geo *to, enum map_datum to_datum) |
int | transform_point (struct transformation *t, enum projection pro, struct coord *c, struct point *p) |
int | transform_point_buf (struct transformation *t, enum projection pro, struct coord *c, struct point *p, long result_size, int count, int mindist, int width, int *width_return) |
int | transform_reverse (struct transformation *t, struct point *p, struct coord *c) |
double | transform_pixels_to_map_distance (struct transformation *transformation, int pixels) |
enum projection | transform_get_projection (struct transformation *this_) |
void | transform_set_projection (struct transformation *this_, enum projection pro) |
struct map_selection * | transform_get_selection (struct transformation *this_, enum projection pro, int order) |
struct coord * | transform_center (struct transformation *this_) |
struct coord * | transform_get_center (struct transformation *this_) |
void | transform_set_center (struct transformation *this_, struct coord *c) |
void | transform_set_yaw (struct transformation *t, int yaw) |
int | transform_get_yaw (struct transformation *this_) |
void | transform_set_pitch (struct transformation *this_, int pitch) |
int | transform_get_pitch (struct transformation *this_) |
void | transform_set_roll (struct transformation *this_, int roll) |
int | transform_get_roll (struct transformation *this_) |
void | transform_set_distance (struct transformation *this_, int distance) |
int | transform_get_distance (struct transformation *this_) |
void | transform_set_scales (struct transformation *this_, int xscale, int yscale, int wscale) |
void | transform_set_screen_selection (struct transformation *t, struct map_selection *sel) |
void | transform_set_screen_center (struct transformation *t, struct point *p) |
void | transform_get_size (struct transformation *t, int *width, int *height) |
void | transform_setup (struct transformation *t, struct pcoord *c, int scale, int yaw) |
void | transform_setup_source_rect (struct transformation *t) |
long | transform_get_scale (struct transformation *t) |
void | transform_set_scale (struct transformation *t, long scale) |
int | transform_get_order (struct transformation *t) |
double | transform_scale (int y) |
double | transform_distance (enum projection pro, struct coord *c1, struct coord *c2) |
Calculates the distance between two points. More... | |
void | transform_project (enum projection pro, struct coord *c, int distance, int angle, struct coord *res) |
double | transform_polyline_length (enum projection pro, struct coord *c, int count) |
int | transform_distance_sq (struct coord *c1, struct coord *c2) |
Determines the squared Mercator distance between two points. More... | |
navit_float | transform_distance_sq_float (struct coord *c1, struct coord *c2) |
int | transform_distance_sq_pc (struct pcoord *c1, struct pcoord *c2) |
int | transform_distance_line_sq (struct coord *l0, struct coord *l1, struct coord *ref, struct coord *lpnt) |
Determines the point on a line segment that is closest to a reference point, and its distance from the reference point. More... | |
navit_float | transform_distance_line_sq_float (struct coord *l0, struct coord *l1, struct coord *ref, struct coord *lpnt) |
int | transform_distance_polyline_sq (struct coord *c, int count, struct coord *ref, struct coord *lpnt, int *pos) |
Determines the point on a polyline that is closest to a reference point, and its distance from the reference point. More... | |
int | transform_douglas_peucker (struct coord *in, int count, int dist_sq, struct coord *out) |
int | transform_douglas_peucker_float (struct coord *in, int count, navit_float dist_sq, struct coord *out) |
void | transform_print_deg (double deg) |
int | transform_get_angle_delta (struct coord *c1, struct coord *c2, int dir) |
Gets the bearing from one point to another. More... | |
int | transform_within_border (struct transformation *this_, struct point *p, int border) |
int | transform_within_dist_point (struct coord *ref, struct coord *c, int dist) |
int | transform_within_dist_line (struct coord *ref, struct coord *c0, struct coord *c1, int dist) |
int | transform_within_dist_polyline (struct coord *ref, struct coord *c, int count, int close, int dist) |
int | transform_within_dist_polygon (struct coord *ref, struct coord *c, int count, int dist) |
int | transform_within_dist_item (struct coord *ref, enum item_type type, struct coord *c, int count, int dist) |
void | transform_copy (struct transformation *src, struct transformation *dst) |
void | transform_destroy (struct transformation *t) |
#define TRANSFORM_ERR_BUF_SPACE -1 |
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 Library 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 Library General Public License for more details.
You should have received a copy of the GNU Library 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 transform_cart_to_geo | ( | struct coord_geo_cart * | cart, |
navit_float | a, | ||
navit_float | b, | ||
struct coord_geo * | geo | ||
) |
Transforms Cartesian to geodetic coordinates.
This transforms ECEF Cartesian coordinates into geodetic coordinates, consisting of latitude and longitude.
cart | The Cartesian coordinates |
a | Semi-minor axis of the ellipsoid |
b | Semi-minor axis of the ellipsoid |
geo | Points to a structure that will receive the geodetic coordinates |
References coord_geo::lat, lat, coord_geo::lng, M_PI, navit_atan, navit_sin, navit_sqrt, navit_tan, coord_geo_cart::x, coord_geo_cart::y, and coord_geo_cart::z.
struct coord* transform_center | ( | struct transformation * | this_ | ) |
References transformation::map_center.
Referenced by bookmarks_set_center_from_file(), bookmarks_write_center_to_file(), keypress(), navit_projection_set(), navit_scale(), and navit_set_center().
void transform_copy | ( | struct transformation * | src, |
struct transformation * | dst | ||
) |
Referenced by navit_handle_button(), and navit_predraw().
void transform_datum | ( | struct coord_geo * | from, |
enum map_datum | from_datum, | ||
struct coord_geo * | to, | ||
enum map_datum | to_datum | ||
) |
void transform_destroy | ( | struct transformation * | t | ) |
References transformation::map_sel, map_selection_destroy(), and transformation::screen_sel.
Referenced by graphics_displaylist_destroy(), graphics_displaylist_draw(), graphics_load_mapset(), navit_motion_timeout(), and vehicle_destroy().
double transform_distance | ( | enum projection | pro, |
struct coord * | c1, | ||
struct coord * | c2 | ||
) |
Calculates the distance between two points.
pro | The projection used for c1 and c2 . |
c1 | The first point. |
c2 | The second point. |
References c1, c2, dbg, lvl_error, projection_garmin, projection_mg, transform_distance_garmin(), and transform_scale().
Referenced by Backend::get_pois(), NGQPoint::getPOI(), gui_internal_cmd2_route_height_profile(), gui_internal_cmd_pois(), model_poi(), navigation_way_get_max_delta(), osd_compass_draw(), osd_odometer_draw(), osd_route_guard_draw(), osd_speed_cam_draw(), route_destination_reached(), route_graph_add_street(), route_info_distances(), route_path_new(), tracking_update(), traffic_location_get_point_triple(), traffic_location_populate_route_graph(), traffic_message_add_segments(), traffic_route_flood_graph(), transform_get_projection(), transform_polyline_length(), and vehicle_demo_timer().
int transform_distance_line_sq | ( | struct coord * | l0, |
struct coord * | l1, | ||
struct coord * | ref, | ||
struct coord * | lpnt | ||
) |
Determines the point on a line segment that is closest to a reference point, and its distance from the reference point.
l0 | The first coordinate of the line segment |
l1 | The second coordinate of the line segment |
ref | The reference point |
lpnt | Receives the coordinates of the point on the line segment that is closest to ref , can be NULL |
ref
and lpnt
, or INT_MAX
if an overflow occurred References c1, c2, transform_distance_sq(), transform_overflow_possible_if_squared(), coord::x, and coord::y.
Referenced by osd_route_guard_draw(), tracking_update(), tracking_value(), transform_distance_polyline_sq(), and transform_douglas_peucker().
navit_float transform_distance_line_sq_float | ( | struct coord * | l0, |
struct coord * | l1, | ||
struct coord * | ref, | ||
struct coord * | lpnt | ||
) |
References c1, c2, transform_distance_sq_float(), coord::x, and coord::y.
Referenced by transform_douglas_peucker_float().
int transform_distance_polyline_sq | ( | struct coord * | c, |
int | count, | ||
struct coord * | ref, | ||
struct coord * | lpnt, | ||
int * | pos | ||
) |
Determines the point on a polyline that is closest to a reference point, and its distance from the reference point.
c | An array containing the coordinates of the polyline |
count | Number of elements in c |
ref | The reference point |
lpnt | Receives the coordinates of the point on the polyline that is closest to ref , can be NULL |
pos | Receives the index of the line segment containing lpnt , can be NULL |
ref
and lpnt
, or INT_MAX
if an overflow occurred References c, startup::pos, and transform_distance_line_sq().
Referenced by route_find_nearest_street(), and route_path_get_distances().
Determines the squared Mercator distance between two points.
c0 | The first coordinate |
c1 | The second coordinate |
c1
and c2
, or INT_MAX
if an overflow occurs. References c1, c2, and transform_overflow_possible_if_squared().
Referenced by osd_speed_cam_draw(), search_house_number_coordinate(), transform_distance_line_sq(), and transform_distance_sq_pc().
navit_float transform_distance_sq_float | ( | struct coord * | c1, |
struct coord * | c2 | ||
) |
Referenced by transform_distance_line_sq_float().
References c1, c2, transform_distance_sq(), coord::x, and coord::y.
References dist_sq(), and transform_distance_line_sq().
Referenced by vehicle_log_binfile().
int transform_douglas_peucker_float | ( | struct coord * | in, |
int | count, | ||
navit_float | dist_sq, | ||
struct coord * | out | ||
) |
References dist_sq(), and transform_distance_line_sq_float().
struct transformation* transform_dup | ( | struct transformation * | t | ) |
References transformation::map_sel, map_selection_dup(), and transformation::screen_sel.
Referenced by graphics_displaylist_draw(), graphics_load_mapset(), and navit_motion_timeout().
void transform_from_geo | ( | enum projection | pro, |
const struct coord_geo * | g, | ||
struct coord * | c | ||
) |
Transform the coordinates of a geographical point from a geographical (lat, long) representation to a coord representation.
pro | The projection to use during the transformation | |
[in] | g | The coordinates as coord_geo (latitude, longitude) |
[out] | c | The coordinates converted to a struct coord format |
References c, geo2gar_units, coord_geo::lat, coord_geo::lng, M_PI, M_PI_4, navit_tan, transformation::pro, projection_garmin, projection_mg, pcoord::x, and pcoord::y.
Referenced by NGQPoint::_coordName(), coord_parse(), NGQProxyNavit::getPosition(), gui_internal_cmd2_pois(), gui_internal_cmd_map_download_do(), gui_internal_cmd_position_do(), gui_internal_set_position_coord(), Java_org_navitproject_navit_NavitCallbackHandler_callbackMessageChannel(), map_rect_get_item_csv(), navit_cmd_map_add_curr_pos(), navit_new(), navit_projection_set(), navit_set_attr_do(), navit_vehicle_update_position(), osd_compass_draw(), osd_odometer_draw(), osd_route_guard_draw(), osd_speed_cam_draw(), route_find_nearest_street(), route_set_attr(), shapefile_coord(), tracking_doupdate_lines(), tracking_update(), traffic_location_get_point_triple(), traffic_location_get_rect(), traffic_message_add_segments(), traffic_traff_android_position_callback(), transform_from_to(), transform_from_to_count(), transform_get_selection(), and vehicle_log_binfile().
void transform_from_to | ( | struct coord * | cfrom, |
enum projection | from, | ||
struct coord * | cto, | ||
enum projection | to | ||
) |
References transform_from_geo(), and transform_to_geo().
Referenced by bookmarks_append_destinations(), item_coord_get_pro(), map_selection_dup_pro(), navit_set_center(), shapefile_coord(), and tracking_map_item_coord_get().
void transform_from_to_count | ( | struct coord * | cfrom, |
enum projection | from, | ||
struct coord * | cto, | ||
enum projection | to, | ||
int | count | ||
) |
References transform_from_geo(), and transform_to_geo().
Referenced by do_draw().
void transform_geo_to_cart | ( | struct coord_geo * | geo, |
navit_float | a, | ||
navit_float | b, | ||
struct coord_geo_cart * | cart | ||
) |
Transforms geodetic to Cartesian coordinates.
This transforms geodetic coordinates (consisting of latitude and longitude) into ECEF Cartesian coordinates.
geo | The WGS84 coordinates to convert |
a | Semi-minor axis of the ellipsoid |
b | Semi-minor axis of the ellipsoid |
cart | Points to a structure that will receive the Cartesian coordinates |
References coord_geo::lat, coord_geo::lng, navit_cos, navit_sin, coord_geo_cart::x, coord_geo_cart::y, and coord_geo_cart::z.
Gets the bearing from one point to another.
c1 | The first coordinate |
c2 | The second coordinate |
dir | The direction: if it is -1, the bearing from c2 to c1 is returned, else the bearing from c1 to c2 |
Referenced by NGQPoint::getPOI(), gui_internal_cmd_pois_item(), model_poi(), pedestrian_draw_arrows(), road_angle(), tracking_get_angles(), and vehicle_demo_timer().
int transform_get_attr | ( | struct transformation * | this_, |
enum attr_type | type, | ||
struct attr * | attr, | ||
struct attr_iter * | iter | ||
) |
References attr::num, attr::type, type, and attr::u.
struct coord* transform_get_center | ( | struct transformation * | this_ | ) |
References transformation::map_center.
Referenced by navit_get_attr(), osd_auxmap_draw(), pedestrian_draw_arrows(), and update_transformation().
int transform_get_distance | ( | struct transformation * | this_ | ) |
References transformation::screen_dist.
Referenced by keypress().
int transform_get_hog | ( | struct transformation * | this_ | ) |
References HOG.
Referenced by keypress().
int transform_get_order | ( | struct transformation * | t | ) |
References dbg, lvl_debug, and transformation::order.
Referenced by graphics_displaylist_draw(), and graphics_load_mapset().
int transform_get_pitch | ( | struct transformation * | this_ | ) |
References transformation::pitch.
Referenced by keypress(), and navit_get_attr().
enum projection transform_get_projection | ( | struct transformation * | this_ | ) |
References c, transformation::screen_center, transform_distance(), transform_reverse(), point::x, and point::y.
Referenced by NGQPoint::_coordName(), bookmarks_set_center_from_file(), bookmarks_write_center_to_file(), do_draw(), Backend::get_bookmarks(), Backend::get_pois(), NGQProxyNavit::getPosition(), gui_internal_set_click_coord(), gui_internal_set_position_coord(), Java_org_navitproject_navit_NavitCallbackHandler_callbackMessageChannel(), Java_org_navitproject_navit_NavitGraphics_getCoordForPoint(), model_poi(), navit_autozoom(), navit_get_attr(), navit_get_coord(), navit_init(), navit_projection_set(), navit_set_attr_do(), navit_set_center(), navit_set_center_screen(), navit_vehicle_draw(), navit_vehicle_update_position(), navit_zoom_to_rect(), NGQPoint::NGQPoint(), osd_auxmap_draw(), popup(), popup_set_destination(), popup_show_item(), NGQPoint::setNewPoint(), and Backend::showMenu().
int transform_get_roll | ( | struct transformation * | this_ | ) |
long transform_get_scale | ( | struct transformation * | t | ) |
References transformation::scale.
Referenced by navit_autozoom(), navit_get_attr(), navit_set_attr_do(), navit_zoom_in(), navit_zoom_out(), and pedestrian_rocket_idle().
struct map_selection* transform_get_selection | ( | struct transformation * | this_, |
enum projection | pro, | ||
int | order | ||
) |
References map_selection::c_rect, dbg, item_range_all, coord_geo::lat, coord_geo::lng, coord_rect::lu, lvl_debug, transformation::map_sel, map_selection_dup(), map_selection::next, map_selection::order, transformation::pro, map_selection::range, coord_rect::rl, transform_from_geo(), transform_to_geo(), map_selection::u, coord::x, and coord::y.
Referenced by displaylist_get_selection().
void transform_get_size | ( | struct transformation * | t, |
int * | width, | ||
int * | height | ||
) |
References height, point_rect::lu, map_selection::p_rect, point_rect::rl, transformation::screen_sel, map_selection::u, width, point::x, and point::y.
Referenced by gui_internal_keypress(), gui_internal_set_graphics(), gui_qml_keypress(), gui_qt5_qml_set_graphics(), info_action(), keypress(), navit_autozoom(), navit_get_cursor_pnt(), navit_set_center_coord_screen(), navit_zoom_to_rect(), and WndProc().
int transform_get_yaw | ( | struct transformation * | this_ | ) |
References transformation::yaw.
Referenced by keypress(), navit_vehicle_draw(), and osd_auxmap_draw().
struct transformation* transform_new | ( | struct pcoord * | center, |
int | scale, | ||
int | yaw | ||
) |
References center, transformation::map_center, transformation::order_base, transformation::pro, transformation::scale, transform_set_screen_dist(), transform_set_yaw(), coord::x, coord::y, and transformation::yaw.
Referenced by navit_new(), and vehicle_new().
double transform_pixels_to_map_distance | ( | struct transformation * | transformation, |
int | pixels | ||
) |
Referenced by osd_scale_draw().
int transform_point | ( | struct transformation * | t, |
enum projection | pro, | ||
struct coord * | c, | ||
struct point * | p | ||
) |
References transform_point_buf().
Referenced by gui_internal_cmd_position_do(), navit_autozoom(), navit_vehicle_draw(), navit_vehicle_update_position(), and navit_zoom_to_rect().
int transform_point_buf | ( | struct transformation * | t, |
enum projection | pro, | ||
struct coord * | c, | ||
struct point * | p, | ||
long | result_size, | ||
int | count, | ||
int | mindist, | ||
int | width, | ||
int * | width_return | ||
) |
References dbg, transformation::ddd, lvl_debug, transformation::offx, transformation::offy, POST_SHIFT, transform_correct_projection(), TRANSFORM_ERR_BUF_SPACE, transform_points_too_close(), transform_project_onto_view_plane(), transform_rotate(), transform_shift_by_center_and_scale(), transform_z_clip_if_necessary(), width, transformation::wscale, point::x, coord_3d::x, point::y, coord_3d::y, and transformation::znear.
Referenced by displayitem_draw(), displayitem_transform_holes(), graphics_displayitem_within_dist(), and transform_point().
double transform_polyline_length | ( | enum projection | pro, |
struct coord * | c, | ||
int | count | ||
) |
References c, and transform_distance().
Referenced by route_info_distances().
void transform_print_deg | ( | double | deg | ) |
void transform_project | ( | enum projection | pro, |
struct coord * | c, | ||
int | distance, | ||
int | angle, | ||
struct coord * | res | ||
) |
References c, dbg, lvl_error, M_PI, projection_mg, transform_scale(), coord::x, pcoord::x, coord::y, and pcoord::y.
Referenced by tracking_update().
int transform_reverse | ( | struct transformation * | t, |
struct point * | p, | ||
struct coord * | c | ||
) |
References c, p, transform_reverse_near_far(), transformation::zfar, and transformation::znear.
Referenced by gui_internal_set_click_coord(), info_action(), Java_org_navitproject_navit_NavitCallbackHandler_callbackMessageChannel(), Java_org_navitproject_navit_NavitGraphics_getCoordForPoint(), model_poi(), navit_scale(), navit_set_center_screen(), NGQPoint::NGQPoint(), popup(), Backend::showMenu(), transform_get_projection(), transform_setup_source_rect(), and update_transformation().
double transform_scale | ( | int | y | ) |
References c, coord_geo::lat, M_PI, navit_cos, projection_mg, transform_to_geo(), pcoord::x, and pcoord::y.
Referenced by Backend::get_pois(), gui_internal_cmd_pois(), model_poi(), osd_route_guard_draw(), transform_distance(), and transform_project().
int transform_set_attr | ( | struct transformation * | this_, |
struct attr * | attr | ||
) |
References attr::num, attr::type, and attr::u.
void transform_set_center | ( | struct transformation * | this_, |
struct coord * | c | ||
) |
References c, and transformation::map_center.
Referenced by navit_set_attr_do(), navit_set_center_coord_screen(), navit_zoom_to_rect(), osd_auxmap_draw(), and update_transformation().
void transform_set_distance | ( | struct transformation * | this_, |
int | distance | ||
) |
References transform_set_screen_dist(), and transform_setup_matrix().
Referenced by keypress(), and pedestrian_navit_init().
void transform_set_hog | ( | struct transformation * | this_, |
int | hog | ||
) |
References dbg, and lvl_error.
Referenced by keypress(), pedestrian_navit_init(), and pedestrian_rocket_idle().
void transform_set_order_base | ( | struct transformation * | this_, |
int | order_base | ||
) |
References transformation::order_base.
Referenced by pedestrian_rocket_idle().
void transform_set_pitch | ( | struct transformation * | this_, |
int | pitch | ||
) |
References transformation::pitch, and transform_setup_matrix().
Referenced by keypress(), navit_set_attr_do(), pedestrian_navit_init(), and pedestrian_read_tilt().
void transform_set_projection | ( | struct transformation * | this_, |
enum projection | pro | ||
) |
References transformation::pro.
Referenced by navit_projection_set(), and osd_auxmap_draw().
void transform_set_roll | ( | struct transformation * | this_, |
int | roll | ||
) |
References dbg, lvl_error, and transform_setup_matrix().
Referenced by pedestrian_navit_init(), and pedestrian_read_tilt().
void transform_set_scale | ( | struct transformation * | t, |
long | scale | ||
) |
References transformation::scale, and transform_setup_matrix().
Referenced by navit_scale(), navit_set_attr_do(), navit_zoom_to_rect(), osd_auxmap_draw(), pedestrian_navit_init(), and pedestrian_rocket_idle().
void transform_set_scales | ( | struct transformation * | this_, |
int | xscale, | ||
int | yscale, | ||
int | wscale | ||
) |
References transformation::wscale3d, transformation::xscale3d, and transformation::yscale3d.
Referenced by pedestrian_navit_init().
void transform_set_screen_center | ( | struct transformation * | t, |
struct point * | p | ||
) |
References p, and transformation::screen_center.
Referenced by vehicle_draw().
void transform_set_screen_selection | ( | struct transformation * | t, |
struct map_selection * | sel | ||
) |
void transform_set_yaw | ( | struct transformation * | t, |
int | yaw | ||
) |
References transform_setup_matrix(), and transformation::yaw.
Referenced by keypress(), navit_set_attr_do(), navit_set_center_cursor(), navit_zoom_to_route(), osd_auxmap_draw(), transform_new(), and vehicle_draw_do().
void transform_setup | ( | struct transformation * | t, |
struct pcoord * | c, | ||
int | scale, | ||
int | yaw | ||
) |
void transform_setup_source_rect | ( | struct transformation * | t | ) |
References c, map_selection::c_rect, coord_rect_extend(), dbg, transformation::ddd, HOG, coord_rect::lu, point_rect::lu, lvl_debug, transformation::map_center, transformation::map_sel, max4(), min4(), map_selection::next, next, map_selection::p_rect, coord_rect::rl, point_rect::rl, transformation::scale_shift, transformation::screen_sel, transform_apply_inverse_matrix(), transform_reverse(), transform_screen_to_3d(), transform_zplane_intersection(), map_selection::u, coord::x, pcoord::x, coord_geo_cart::x, point::x, coord::y, pcoord::y, coord_geo_cart::y, point::y, transformation::zfar, and transformation::znear.
Referenced by navit_draw_async(), navit_zoom_to_rect(), and osd_auxmap_draw().
void transform_to_geo | ( | enum projection | pro, |
const struct coord * | c, | ||
struct coord_geo * | g | ||
) |
Transform the coordinates of a geographical point from a coord representation to a geographical (lat, long) representation.
pro | The projection to use during the transformation | |
[in] | c | The coordinates as a struct coord format |
[out] | g | The coordinates converted to coord_geo (latitude, longitude) |
References c, gar2geo_units, coord_geo::lat, coord_geo::lng, M_PI, navit_atan, transformation::pro, projection_garmin, projection_mg, projection_utm, transform_utm_to_geo(), pcoord::x, and pcoord::y.
Referenced by android_return_search_result(), attr_new_from_text(), coord_parse(), csv_coord_set(), gui_internal_cmd_position_do(), gui_internal_set_click_coord(), itembin_warning(), map_rect_new_csv(), navit_get_attr(), navit_projection_set(), NGQPoint::NGQPoint(), pcoord_format_absolute(), pcoord_format_degree_short(), popup(), popup_set_bookmark(), popup_set_destination(), request_navit_route_export_geojson(), request_navit_route_export_gpx(), request_navit_traffic_export_gpx(), route_find_nearest_street(), NGQPoint::setNewPoint(), Backend::showMenu(), tracking_doupdate_lines(), tracking_get_attr(), traffic_message_add_segments(), traffic_traff_android_set_selection(), transform_from_to(), transform_from_to_count(), transform_get_selection(), transform_scale(), and vehicle_demo_timer().
void transform_utm_to_geo | ( | const double | UTMEasting, |
const double | UTMNorthing, | ||
int | ZoneNumber, | ||
int | NorthernHemisphere, | ||
struct coord_geo * | geo | ||
) |
Converts UTM coords to lat/long.
Equations from USGS Bulletin 1532.
Referenced by transform_to_geo().
int transform_within_border | ( | struct transformation * | this_, |
struct point * | p, | ||
int | border | ||
) |
References point_rect::lu, map_selection::next, p, map_selection::p_rect, point_rect::rl, transformation::screen_sel, map_selection::u, point::x, and point::y.
Referenced by navit_handle_button(), and navit_vehicle_update_position().
int transform_within_dist_item | ( | struct coord * | ref, |
enum item_type | type, | ||
struct coord * | c, | ||
int | count, | ||
int | dist | ||
) |
References c, transform_within_dist_point(), transform_within_dist_polygon(), transform_within_dist_polyline(), and type.
Referenced by NGQPoint::_coordName().
int transform_within_dist_line | ( | struct coord * | ref, |
struct coord * | c0, | ||
struct coord * | c1, | ||
int | dist | ||
) |
References c1, transform_within_dist_point(), coord::x, and coord::y.
Referenced by transform_within_dist_polyline().
References c, coord::x, pcoord::x, coord::y, and pcoord::y.
Referenced by transform_within_dist_item(), and transform_within_dist_line().
References c, transform_within_dist_polyline(), coord::x, pcoord::x, coord::y, and pcoord::y.
Referenced by transform_within_dist_item().
int transform_within_dist_polyline | ( | struct coord * | ref, |
struct coord * | c, | ||
int | count, | ||
int | close, | ||
int | dist | ||
) |
References c, and transform_within_dist_line().
Referenced by transform_within_dist_item(), and transform_within_dist_polygon().
int transformation_get_order_base | ( | struct transformation * | this_ | ) |
References transformation::order_base.