how run ofCurveVertex() ?

Hello,

I’m trying to use ofCurveVertex with this simply code in the draw function :

  
ofBackground(211);  
    ofSetCurveResolution(4);  
    ofSetLineWidth(4);  
	ofSetColor(0, 0, 0);  
	ofNoFill();  
    ofBeginShape();  
    ofCurveVertex(100, 300);  
    ofCurveVertex(120, 200);  
    ofCurveVertex(500, 400);  
    ofEndShape();  

But I have no lines on my app.
I have tried with ofVertex() and I’ve got the black lines.

I’m working with OF 0071 on ubuntuStudio 12.04

Thanks

You need more points for a curve:

  
  
    ofCurveVertex(200, 400);  
    ofCurveVertex(420, 200);  
    ofCurveVertex(500, 100);  
    ofCurveVertex(900, 900);  
  

Check out ofPolyline::curveTo(), you’ll see that it has the following line:

  
  
if (curveVertices.size() == 4){   
// do drawing  
}  
// method ends.  
  

Ok, it’s works now
thanks a lot