I am drawing an outline of a glyph for given character using:
QString myfname="FreeMono.ttf";
QRawFont *myfont=new QRawFont(myfname,324,QFont::PreferDefaultHinting);
QChar mychars[]={'Q','B'};
int numofchars=3;
quint32 myglyphindexes[3];
int numofglyphs;
myfont->glyphIndexesForChars(mychars,numofchars,myglyphindexes,&numofglyphs);
QPainterPath mypath=myfont->pathForGlyph(myglyphindexes[0]);
This path I am drawing on pixmap using
painter.drawPath(mypath)
I want to know how this path is drawn. I mean what type of curves or lines this outline contains. For this I tried this:
QPointF mypoints[49];
for(int i=0; i<mypath.elementAt(i); i++)
{
mypoints[i]=mypath.elementAt(i);
}
This gives me array of points. But how these points are connected with each other like using a line or curve. How can I know that? Also is this a correct approach? What I need to improve?