** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: ezplot.cpp,v 1.10 2000/08/19 22:59:06 kevin Exp $
+** $Id: ezplot.cpp,v 1.12 2000/08/31 08:38:58 kevin Exp $
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License (version 2) as
}
+void
+EZPlot::addCurve (const float *y, int n)
+{
+ double yDouble [n];
+
+ for (int i = 0; i < n; i++)
+ yDouble[i] = y[i];
+
+ addCurve (yDouble, n);
+}
+
+
void
EZPlot::addCurve (const float x[], const double y[], int num)
{
xtl_wid = x_fldwid * charwidth; /* calc size of tick labels */
ytl_wid = y_fldwid * charwidth;
tl_height = charheight;
-
+
+ // rSGP.getViewport (xp_min, yp_min, xp_max, yp_max);
/* calculate the extent of the plot frame */
xp_min = o_xporigin;
yp_min = o_yporigin;
EZPlot::axis_scale (double min, double max, int nint, double *minp, double *maxp, int *nintp)
{
if (min >= max || nint < 1) {
- sys_error (ERR_WARNING, "Invalid params: min=%lf, min=%lf, num intervals=%d [axis_scale]", min, max, nint);
+ sys_error (ERR_WARNING, "Invalid params: min=%lf, max=%lf, num intervals=%d [axis_scale]", min, max, nint);
return (FALSE);
}