Using ofVertex and ofCurveVertex together

OK so I think this is a beginner question, although I’m not quite a beginner, but I just ran into a rather unfortunate problem with OF…I can’t create an object with both straight and curved vertices using ofBeginShape and ofEndShape…

I read this in the ofEndShape() code…

// we drop any “curve calls”
// once a vertex call has been made
// ie,
// you can’t mix
// ofCurveVertex();
// ofCurveVertex();
// ofVertex();
// etc…
// and you need 4 calls
// to curve to see something…

which since I’m basically just trying to make something that looks like a pie chart (2 straight lines and a curve…) sorta sucks for me.

My question is how can I do this? I have a couple ideas:
-Draw a triangle and a circle (probably the best bet but what if I wanna do alpha?)
-use straight openGL
-maybe create a shape with bezier’s using some wiht straight curves? (I don’t think that’d work)
-If I wanna get really brutal do a for loop using sin, cos and the vector length (radius of the chart) and draw a crapload of lines…this is stupid and I don’t wanna do this
-Processing has a function for this (arc), I don’t mind rewriting this for oF based on the processing source code either…

Can any one suggest a way for me to do this?


take a look at this:

Ahhh great, thanks I appreciate it! Looks like my forum searching skills need to be a bit broader, I searched everywhere for pie, chart, pie chart etc but not wedge or slice…doh!