I can't tell because my C skills are pretty bad but looking at fmax and fmin, I'm worried that the X and Y axis might be flipped for example:
LinuxCNC from rtapi_math.h: extern __inline double fmax(double __y, double __x) { return __y > __x || __builtin_isnan(__x) ? __y : __x; } extern __inline double fmin(double __y, double __x) { return __y < __x || __builtin_isnan(__x) ? __y : __x; } RTAI from musl/libm/f{max,min}.c: double fmax(double x, double y) { if (isnan(x)) return y; if (isnan(y)) return x; /* handle signed zeros, see C99 Annex F.9.9.2 */ if (signbit(x) != signbit(y)) return signbit(x) ? y : x; return x < y ? y : x; } double fmin(double x, double y) { if (isnan(x)) return y; if (isnan(y)) return x; /* handle signed zeros, see C99 Annex F.9.9.2 */ if (signbit(x) != signbit(y)) return signbit(x) ? x : y; return x < y ? x : y; } Or maybe everything will just work perfectly fine! :-) Alec _______________________________________________ Emc-developers mailing list Emc-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/emc-developers