I have an old c++ program that I need to bring back to life. My task now is to draw a single Polygon. I am stuck at the very beginning since I have no experience in graphics. The points I want to use to draw a Polygen are stored in
QVector < QPointF> points which looks like that:
Now I want to draw my Polygon. I use this code:
ggScene = new QGraphicsScene();
QPolygonF shape(points);
QGraphicsItem* gg = ggScene->addPolygon(shape);
When compiling I get the following error:
cannot convert QGraphicsPolygonItem* to QGraphiscItem in initialization
Can anybiody help me on this please, thank you.