From e7d20cf352688bf717a01f4e6d9e6f497c2bea4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=B6rg=20Frings-F=C3=BCrst?= Date: Sat, 20 Sep 2025 19:19:34 +0200 Subject: New upstream version 5.3.1Beta2 --- app/bin/tbezier.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'app/bin/tbezier.c') diff --git a/app/bin/tbezier.c b/app/bin/tbezier.c index c5cff99..1fc95b1 100644 --- a/app/bin/tbezier.c +++ b/app/bin/tbezier.c @@ -1227,7 +1227,7 @@ BOOL_T GetTracksFromBezierSegment(trkSeg_p bezSeg, track_p newTracks[2], if (bezSeg->type != SEG_BEZTRK) { return FALSE; } for (int i=0; ibezSegs.cnt; i++) { trkSeg_p seg = &DYNARR_N(trkSeg_t,bezSeg->bezSegs,i); - track_p new_trk; + track_p new_trk = NULL; if (seg->type == SEG_CRVTRK) { new_trk = NewCurvedTrack(seg->u.c.center,fabs(seg->u.c.radius),seg->u.c.a0, seg->u.c.a1,0); @@ -1846,12 +1846,14 @@ static DIST_T BezierMathDistance( coOrd * pos, coOrd p[4], int segments, return dd; } +#ifdef LATER static coOrd BezierMathFindNearestPoint(coOrd *pos, coOrd p[4], int segments) { double t = 0.0; BezierMathDistance(pos, p, segments, &t); return BezierPointByParameter(p, t); } +#endif void BezierSlice(coOrd input[], coOrd output[], double t) { @@ -1937,6 +1939,7 @@ double BezierAddLengthIfClose(coOrd start[4], double error) } +#ifdef LATER /** * Use recursive splitting to get close approximation ot length of bezier * @@ -1947,6 +1950,7 @@ static double BezierMathLength(coOrd p[4], double error) return BezierAddLengthIfClose(p, error); /* kick off recursion */ } +#endif coOrd BezierFirstDerivative(coOrd p[4], double t) { @@ -1988,6 +1992,7 @@ coOrd BezierSecondDerivative(coOrd p[4], double t) return v; } +#ifdef LATER /** * Get curvature of a Bezier at a point */ @@ -2032,4 +2037,4 @@ static double BezierMathMinRadius(coOrd p[4]) if (curv >= 1000.0 || curv <= 0.001 ) { return 0.0; } return 1/curv; } - +#endif -- cgit v1.2.3