Draws a cubic or quadratic bezier