void QCurvePlot::setData(const unsigned int number, const double * xData, const double * yData, int start, int size)
{
if (number <= m_data.size())
{
int arraynumber = number - 1;
if (m_data[arraynumber].x != NULL )
delete [] m_data[arraynumber].x;
if (m_data[arraynumber].y != NULL )
delete [] m_data[arraynumber].y;
m_data[arraynumber].x = new double [size];
m_data[arraynumber].y = new double [size];
memcpy(m_data[arraynumber].x, xData + start, size * sizeof(double));
memcpy(m_data[arraynumber].y, yData + start, size * sizeof(double));
Curve[number].setRawData(m_data[arraynumber].x, m_data[arraynumber].y, size);
}
}
void QCurvePlot::setData(const unsigned int number, const double * xData, const double * yData, int start, int size)
{
if (number <= m_data.size())
{
int arraynumber = number - 1;
if (m_data[arraynumber].x != NULL )
delete [] m_data[arraynumber].x;
if (m_data[arraynumber].y != NULL )
delete [] m_data[arraynumber].y;
m_data[arraynumber].x = new double [size];
m_data[arraynumber].y = new double [size];
memcpy(m_data[arraynumber].x, xData + start, size * sizeof(double));
memcpy(m_data[arraynumber].y, yData + start, size * sizeof(double));
Curve[number].setRawData(m_data[arraynumber].x, m_data[arraynumber].y, size);
}
}
To copy to clipboard, switch view to plain text mode
which however does not use any qwt code at all.
Bookmarks