sujan.dasmahapatra
21st November 2013, 09:59
I have drawn a straight line using QPainterPath.
QPainter painter(this);
QPainterPath path;
path.moveTo(QPointF(B_Point));
path.lineTo(QPointF(D_Point));
painter.drawPath(m_BiscepLoopPath);
BD is a straightline. Now I have to modify this line to a curve so that BD length become 100 pixel. Stright line BD length is only 50. so the line has bend startpoint B and endpoint D remains same but it should match the length to be 100.
Please help me how can I do it.? Thanks Sujan
QPainter painter(this);
QPainterPath path;
path.moveTo(QPointF(B_Point));
path.lineTo(QPointF(D_Point));
painter.drawPath(m_BiscepLoopPath);
BD is a straightline. Now I have to modify this line to a curve so that BD length become 100 pixel. Stright line BD length is only 50. so the line has bend startpoint B and endpoint D remains same but it should match the length to be 100.
Please help me how can I do it.? Thanks Sujan