diff options
author | lecoanet | 2000-03-07 15:10:07 +0000 |
---|---|---|
committer | lecoanet | 2000-03-07 15:10:07 +0000 |
commit | 0563e7837893013ae45a508aa3ece846d64ac3b2 (patch) | |
tree | 44b2fad5c44741b9fda006757d6510ac35023076 | |
parent | 863430f03e019f2c990827b909957bd530e47bbf (diff) | |
download | tkzinc-0563e7837893013ae45a508aa3ece846d64ac3b2.zip tkzinc-0563e7837893013ae45a508aa3ece846d64ac3b2.tar.gz tkzinc-0563e7837893013ae45a508aa3ece846d64ac3b2.tar.bz2 tkzinc-0563e7837893013ae45a508aa3ece846d64ac3b2.tar.xz |
* D�placement de fonctions g�om�triques vers Geo.
-rw-r--r-- | generic/Track.c | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/generic/Track.c b/generic/Track.c index a5e17dc..9a1461f 100644 --- a/generic/Track.c +++ b/generic/Track.c @@ -298,58 +298,6 @@ static ZnAttrConfig wp_attrs[] = { }; -/* - ********************************************************************************** - * - * PointPolarToCartesian -- - * Convert a point in polar coordinates in - * a reference system described by heading - * dx_ref, dy_ref to a point in cartesian - * coordinates. - * - ********************************************************************************** - */ -static ZnReal -ProjectionToAngle(ZnDim dx, - ZnDim dy) -{ - if (dx == 0) { - if (dy < 0) { - return -M_PI_2; - } - else if (dy > 0) { - return M_PI_2; - } - else { - return 0.0; - } - } - else if (dx < 0) { - return atan((double) dy / (double) dx) - M_PI; - } - else { - return atan((double) dy / (double) dx); - } - return 0.0; -} - -static void -PointPolarToCartesian(ZnReal heading, - int rho, - int theta, - int *delta_x, - int *delta_y) -{ - double to_angle; - - /* Compute angle in trigonometric system */ - to_angle = DegreesToRadian(theta) + heading - M_PI_2; - /* to_angle = heading - DegreesToRadian(theta);*/ - /* Compute cartesian coordinates */ - *delta_x = (int) (rho * cos(to_angle)); - *delta_y = (int) (rho * sin(to_angle)); -} - /* ********************************************************************************** |