Correcting calculation of the bezier points.