aboutsummaryrefslogtreecommitdiff
path: root/generic/OverlapMan.c
diff options
context:
space:
mode:
authorlecoanet2000-11-13 10:05:20 +0000
committerlecoanet2000-11-13 10:05:20 +0000
commit00c4b3b40c8a66a6180524763c8495e94049c57c (patch)
tree64223332082099009157a5845a5e22ce1ff4d49c /generic/OverlapMan.c
parent4f2845559939d58ef39560bb027bde5e2b351866 (diff)
downloadtkzinc-00c4b3b40c8a66a6180524763c8495e94049c57c.zip
tkzinc-00c4b3b40c8a66a6180524763c8495e94049c57c.tar.gz
tkzinc-00c4b3b40c8a66a6180524763c8495e94049c57c.tar.bz2
tkzinc-00c4b3b40c8a66a6180524763c8495e94049c57c.tar.xz
Suppression de label_x, label_y, label_width, label_height de fnext_track
Diffstat (limited to 'generic/OverlapMan.c')
-rw-r--r--generic/OverlapMan.c32
1 files changed, 17 insertions, 15 deletions
diff --git a/generic/OverlapMan.c b/generic/OverlapMan.c
index 20765c6..769e395 100644
--- a/generic/OverlapMan.c
+++ b/generic/OverlapMan.c
@@ -72,10 +72,10 @@ typedef struct _INFOS {
int y;
int vv_dx;
int vv_dy;
- int label_x;
+ /* Fri Oct 13 15:15:31 2000 int label_x;
int label_y;
int label_width;
- int label_height;
+ int label_height;*/
int rho;
int theta;
int visibility;
@@ -444,10 +444,10 @@ PutTrackLoaded(int iw)
}
else {
if (info1.visibility == FALSE) {
- SetTrackInitValues( iw, pos);
+ SetTrackInitValues( iw, pos);
}
else {
- SetTrackCurrentValues(iw,pos);
+ SetTrackCurrentValues(iw, pos);
}
}
@@ -476,8 +476,10 @@ ReadTracks(int iw)
while ((info1.id = (*wr[iw]._next_track)(wr[iw].rw, info1.id,
&info1.x, &info1.y,
&info1.vv_dx, &info1.vv_dy,
+ /* Fri Oct 13 15:15:48 2000
&info1.label_x, &info1.label_y,
&info1.label_width, &info1.label_height,
+ */
&info1.rho, &info1.theta,
&info1.visibility))) {
info1.alpha = (ProjToAngle(info1.vv_dx, info1.vv_dy ) - M_PI_2 +
@@ -578,8 +580,8 @@ SetupLeaderPosition(int iw,
double D, k, Fx0, Fy0;
int jp;
double alpha;
- BOOLEAN ok=FALSE;
- double dx,dy;
+ BOOLEAN ok = FALSE;
+ double dx, dy;
Fx0 = 0.0;
Fy0 = 0.0;
@@ -642,7 +644,7 @@ SetupLeaderPosition(int iw,
if (ok) {
wr[iw].infos[ip].dx = (int) dx;
wr[iw].infos[ip].dy = (int) dy;
- wr[iw].infos[ip].alpha = ProjToAngle((int) dx,(int) dy);
+ wr[iw].infos[ip].alpha = ProjToAngle((int) dx, (int) dy);
}
}
@@ -741,8 +743,8 @@ ComputeDrawback(int iw,
int ip)
{
int vx, vy, dx, dy;
- double m=0;
- double nd=1.0, nv=1.0;
+ double m = 0;
+ double nd = 1.0, nv = 1.0;
double vi;
vx = wr[iw].infos[ip].vv_dx;
@@ -758,8 +760,8 @@ ComputeDrawback(int iw,
}
vi = (double) (vx * dx + vy * dy)/(nd * nv);
- vi = vi < -1.0 ? -1.0 : vi;
- vi = vi > 1.0 ? 1.0 : vi;
+ vi = vi <= -1.0 ? -1.0 : vi;
+ vi = vi >= 1.0 ? 1.0 : vi;
vi = 3 * M_PI_4 - acos(vi);
if (vy * dx - vx * dy < 0) {
@@ -799,8 +801,8 @@ DrawbackDirection(int vx,
}
vi = (double) (vx * dx + vy * dy)/(nd * nv);
- vi = vi < -1.0 ? -1.0 : vi;
- vi = vi > 1.0 ? 1.0 : vi;
+ vi = vi <= -1.0 ? -1.0 : vi;
+ vi = vi >= 1.0 ? 1.0 : vi;
vi = acos(vi);
if (vy * dx - vx * dy < 0) {
@@ -824,7 +826,7 @@ ComputeDrawbackInView(int iw,
int dx, dy;
double Gamma=0;
- r= wr[iw].infos[ip].rho;
+ r = wr[iw].infos[ip].rho;
dx = wr[iw].infos[ip].dx;
dy = wr[iw].infos[ip].dy;
@@ -838,7 +840,7 @@ ComputeDrawbackInView(int iw,
Gamma += DrawbackDirection(0, 53, dx, dy);
}
if (abs(wr[iw].infos[ip].y - height) < r) {
- Gamma += DrawbackDirection(0,-53, dx, dy);
+ Gamma += DrawbackDirection(0,- 53, dx, dy);
}
return (double) Gamma;