May be the problem was not clearly stated. I was not reading the values corresponding to the sinus curve inside coordinates. For some reason it seems that the data become available in coordinates only after a replot. May be some one can discuss what happens behind the scenes...

For me it was sufficient to do this:

Qt Code:
  1. double *xSin = new double[size];
  2. double *ySin = new double[size];
  3. for(int i = 0; i < size; i++){ /* Gera pontos do seno. */
  4. xSin[i] = i;
  5. ySin[i] = ::sin(i);
  6. }
To copy to clipboard, switch view to plain text mode