i know i can draw an ellipse in Qt with QPainter. But i want to rotate the Ellipse inside a QPainterpath. Does anybody know how i can do that?
The goal is to subtract two ellipses. I know that i can subtract two ellipses by subtracting two QPainterPaths. So my idea was to do that using the QPainterpath. But i dont know how i am able to rotate the ellipse inside my QPainterPath oder how i can rotate the QPainterPath.
But there is no function such as
QPainterPath path;
path.addEllipse(100,100,100,100);
path.rotate(45);
You can rotate each point and
controlPointof path elements:You must define a
centerPointfor rotation:QPointF(125,150))You drew a circular ellipse, you can't see if it's rotated when
centerPointis at ellipse's center.Usage: