#include <vcubicbezierpath.h>
Public Member Functions | |
| VCubicBezierPath (quint32 idObject=0, Draw mode=Draw::Calculation) | |
| VCubicBezierPath (const VCubicBezierPath &curve) | |
| VCubicBezierPath (const QVector< VPointF > &points, quint32 idObject=0, Draw mode=Draw::Calculation) | |
| VCubicBezierPath | Rotate (const QPointF &originPoint, qreal degrees, const QString &prefix=QString()) const |
| VCubicBezierPath | Flip (const QLineF &axis, const QString &prefix=QString()) const |
| VCubicBezierPath | Move (qreal length, qreal angle, const QString &prefix=QString()) const |
| virtual | ~VCubicBezierPath () |
| VCubicBezierPath & | operator= (const VCubicBezierPath &curve) |
| void | Swap (VCubicBezierPath &curve) Q_DECL_NOTHROW |
| VPointF & | operator[] (int indx) |
| const VPointF & | at (int indx) const |
| void | append (const VPointF &point) |
| virtual qint32 | CountSubSpl () const Q_DECL_OVERRIDE |
| virtual qint32 | CountPoints () const Q_DECL_OVERRIDE |
| virtual void | Clear () Q_DECL_OVERRIDE |
| virtual VSpline | GetSpline (qint32 index) const Q_DECL_OVERRIDE |
| virtual qreal | GetStartAngle () const Q_DECL_OVERRIDE |
| virtual qreal | GetEndAngle () const Q_DECL_OVERRIDE |
| virtual qreal | GetC1Length () const Q_DECL_OVERRIDE |
| virtual qreal | GetC2Length () const Q_DECL_OVERRIDE |
| virtual QVector< VSplinePoint > | GetSplinePath () const Q_DECL_OVERRIDE |
| QVector< VPointF > | GetCubicPath () const |
| virtual VPointF | FirstPoint () const Q_DECL_OVERRIDE |
| virtual VPointF | LastPoint () const Q_DECL_OVERRIDE |
Public Member Functions inherited from VAbstractCubicBezierPath | |
| VAbstractCubicBezierPath (const GOType &type, const quint32 &idObject=null_id, const Draw &mode=Draw::Calculation) | |
| VAbstractCubicBezierPath (const VAbstractCubicBezierPath &curve) | |
| VAbstractCubicBezierPath & | operator= (const VAbstractCubicBezierPath &curve) |
| virtual | ~VAbstractCubicBezierPath () |
| virtual QPainterPath | GetPath () const Q_DECL_OVERRIDE |
| GetPath return QPainterPath which reprezent spline path. More... | |
| virtual QVector< QPointF > | getPoints () const Q_DECL_OVERRIDE |
| GetPathPoints return list of points what located on path. More... | |
| virtual qreal | GetLength () const Q_DECL_OVERRIDE |
| GetLength return length of spline path. More... | |
| virtual QVector< DirectionArrow > | DirectionArrows () const Q_DECL_OVERRIDE |
| int | Segment (const QPointF &p) const |
| QPointF | CutSplinePath (qreal length, qint32 &p1, qint32 &p2, QPointF &spl1p2, QPointF &spl1p3, QPointF &spl2p2, QPointF &spl2p3) const |
| CutSplinePath cut spline path into two. This method don't return two spline path. You must create spline paths by yourself. Example: QPointF spl1p2, spl1p3, spl2p2, spl2p3; qint32 p1 = 0, p2 = 0; QPointF point = splPath->CutSplinePath(length, p1, p2, spl1p2, spl1p3, spl2p2, spl2p3);. More... | |
| virtual QString | NameForHistory (const QString &toolName) const Q_DECL_OVERRIDE |
| NameForHistory helps to create name for dialog History. More... | |
Public Member Functions inherited from VAbstractBezier | |
| VAbstractBezier (const GOType &type, const quint32 &idObject=null_id, const Draw &mode=Draw::Calculation) | |
| VAbstractBezier (const VAbstractBezier &curve) | |
| VAbstractBezier & | operator= (const VAbstractBezier &curve) |
| virtual | ~VAbstractBezier () |
Public Member Functions inherited from VAbstractCurve | |
| VAbstractCurve (const GOType &type, const quint32 &idObject=null_id, const Draw &mode=Draw::Calculation) | |
| VAbstractCurve (const VAbstractCurve &curve) | |
| virtual | ~VAbstractCurve () Q_DECL_OVERRIDE |
| VAbstractCurve & | operator= (const VAbstractCurve &curve) |
| void | Swap (VAbstractCurve &curve) Q_DECL_NOTHROW |
| QVector< QPointF > | GetSegmentPoints (const QPointF &begin, const QPointF &end, bool reverse=false) const |
| qreal | GetLengthByPoint (const QPointF &point) const |
| virtual QVector< QPointF > | IntersectLine (const QLineF &line) const |
| IntersectLine return list of points for real intersection with line. More... | |
| virtual bool | IsIntersectLine (const QLineF &line) const |
| bool | isPointOnCurve (const QPointF &p) const |
| quint32 | GetDuplicate () const |
| void | SetDuplicate (quint32 number) |
| QString | getLineColor () const |
| void | setLineColor (const QString &color) |
| QString | GetPenStyle () const |
| void | SetPenStyle (const QString &penStyle) |
| QString | getLineWeight () const |
| getLineWeight return weight of the lines More... | |
| void | setLineWeight (const QString &lineWeight) |
| setLineWeight set weight of the lines More... | |
| QPointF | getFirstPoint () |
| QPointF | getLastPoint () |
Public Member Functions inherited from VGObject | |
| VGObject () | |
| VGObject default constructor. More... | |
| VGObject (const GOType &type, const quint32 &idObject=0, const Draw &mode=Draw::Calculation) | |
| VGObject constructor. More... | |
| VGObject (const VGObject &obj) | |
| VGObject copy constructor. More... | |
| virtual | ~VGObject () |
| VGObject & | operator= (const VGObject &obj) |
| operator = assignment operator. More... | |
| void | Swap (VGObject &obj) Q_DECL_NOTHROW |
| quint32 | getIdObject () const |
| getIdObject return parent id. More... | |
| void | setIdObject (const quint32 &value) |
| setIdObject set parent id. More... | |
| virtual QString | name () const |
| name return name graphical object. More... | |
| void | setName (const QString &name) |
| setName set name graphical object. More... | |
| Draw | getMode () const |
| getMode return mode creation. More... | |
| void | setMode (const Draw &value) |
| setMode set mode creation. More... | |
| GOType | getType () const |
| getType return object type. More... | |
| void | setType (const GOType &type) |
| quint32 | id () const |
| id return id object. More... | |
| virtual void | setId (const quint32 &id) |
| setId set id object. More... | |
| quint32 | getIdTool () const |
Static Public Member Functions | |
| static qint32 | CountSubSpl (qint32 size) |
| static qint32 | SubSplOffset (qint32 subSplIndex) |
| static qint32 | SubSplPointsCount (qint32 countSubSpl) |
Static Public Member Functions inherited from VAbstractCurve | |
| static QVector< QPointF > | GetSegmentPoints (const QVector< QPointF > &points, const QPointF &begin, const QPointF &end, bool reverse=false) |
| static bool | isPointOnCurve (const QVector< QPointF > &points, const QPointF &p) |
| static qreal | PathLength (const QVector< QPointF > &path) |
| static QVector< QPointF > | CurveIntersectLine (const QVector< QPointF > &points, const QLineF &line) |
| static QPainterPath | ShowDirection (const QVector< DirectionArrow > &arrows, qreal width) |
Static Public Member Functions inherited from VGObject | |
| static QLineF | BuildLine (const QPointF &p1, const qreal &length, const qreal &angle) |
| static QPointF | BuildRay (const QPointF &firstPoint, const qreal &angle, const QRectF &scRect) |
| static QLineF | BuildAxis (const QPointF &p, const qreal &angle, const QRectF &scRect) |
| static QLineF | BuildAxis (const QPointF &p1, const QPointF &p2, const QRectF &scRect) |
| static int | ContactPoints (const QPointF &p, const QPointF ¢er, qreal radius, QPointF &p1, QPointF &p2) |
| static QPointF | LineIntersectRect (const QRectF &rec, const QLineF &line) |
| LineIntersectRect find point intersection line and rect. More... | |
| static int | IntersectionCircles (const QPointF &c1, double r1, const QPointF &c2, double r2, QPointF &p1, QPointF &p2) |
| static qint32 | LineIntersectCircle (const QPointF ¢er, qreal radius, const QLineF &line, QPointF &p1, QPointF &p2) |
| LineIntersectCircle find point intersection line and circle. More... | |
| static QPointF | ClosestPoint (const QLineF &line, const QPointF &point) |
| ClosestPoint find point projection of point onto line. More... | |
| static QPointF | addVector (const QPointF &p, const QPointF &p1, const QPointF &p2, qreal k) |
| static void | LineCoefficients (const QLineF &line, qreal *a, qreal *b, qreal *c) |
| LineCoefficients coefficient for equation of segment. Segment equestion ax+by+c=0. More... | |
| static bool | IsPointOnLineSegment (const QPointF &t, const QPointF &p1, const QPointF &p2) |
| IsPointOnLineSegment Check if the point is on the line segment. More... | |
| static bool | IsPointOnLineviaPDP (const QPointF &t, const QPointF &p1, const QPointF &p2) |
| IsPointOnLineviaPDP use the perp dot product (PDP) way. More... | |
| template<typename T > | |
| static QVector< T > | GetReversePoints (const QVector< T > &points) |
| GetReversePoint return revers container of points. More... | |
| static int | GetLengthContour (const QVector< QPointF > &contour, const QVector< QPointF > &newPoints) |
| GetLengthContour return length of contour. More... | |
Private Attributes | |
| QSharedDataPointer< VCubicBezierPathData > | d |
Additional Inherited Members | |
Static Public Attributes inherited from VAbstractCurve | |
| static const qreal | lengthCurveDirectionArrow = 14 |
Static Public Attributes inherited from VGObject | |
| static const double | accuracyPointOnLine = (0.1555 / 25.4) * 96.0 |
Protected Member Functions inherited from VAbstractCubicBezierPath | |
| virtual void | CreateName () Q_DECL_OVERRIDE |
Static Protected Member Functions inherited from VGObject | |
| static QTransform | flipTransform (const QLineF &axis) |
Definition at line 65 of file vcubicbezierpath.h.
|
explicit |
Definition at line 73 of file vcubicbezierpath.cpp.
References CubicBezierPath.
| VCubicBezierPath::VCubicBezierPath | ( | const VCubicBezierPath & | curve | ) |
Definition at line 80 of file vcubicbezierpath.cpp.
| VCubicBezierPath::VCubicBezierPath | ( | const QVector< VPointF > & | points, |
| quint32 | idObject = 0, |
||
| Draw | mode = Draw::Calculation |
||
| ) |
Definition at line 87 of file vcubicbezierpath.cpp.
References VAbstractCubicBezierPath::CreateName(), CubicBezierPath, and d.
|
virtual |
Definition at line 161 of file vcubicbezierpath.cpp.
| void VCubicBezierPath::append | ( | const VPointF & | point | ) |
Definition at line 178 of file vcubicbezierpath.cpp.
References VAbstractCubicBezierPath::CreateName(), and d.
| const VPointF & VCubicBezierPath::at | ( | int | indx | ) | const |
Definition at line 172 of file vcubicbezierpath.cpp.
References d.
Referenced by DialogCubicBezierPath::currentPointChanged(), DialogCubicBezierPath::SetPath(), and VToolCubicBezierPath::UpdatePathPoints().
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 197 of file vcubicbezierpath.cpp.
References d, and VAbstractCurve::SetDuplicate().
Referenced by DialogCubicBezierPath::SavePath().
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 191 of file vcubicbezierpath.cpp.
References d.
Referenced by DialogCubicBezierPath::ChosenObject(), DialogCubicBezierPath::currentPointChanged(), GetSpline(), DialogCubicBezierPath::IsPathValid(), VisToolCubicBezierPath::RefreshToolTip(), DialogCubicBezierPath::SetPath(), DialogCubicBezierPath::ShowDialog(), and VToolCubicBezierPath::UpdatePathPoints().
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 185 of file vcubicbezierpath.cpp.
References d.
Referenced by DialogCubicBezierPath::AllPathBackboneIds(), VisToolCubicBezierPath::Creating(), GetC1Length(), GetC2Length(), GetEndAngle(), GetSpline(), GetSplinePath(), GetStartAngle(), DialogCubicBezierPath::IsPathValid(), LastPoint(), VisToolCubicBezierPath::RefreshGeometry(), VisToolCubicBezierPath::RefreshToolTip(), and DialogCubicBezierPath::ShowDialog().
|
static |
Definition at line 324 of file vcubicbezierpath.cpp.
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 356 of file vcubicbezierpath.cpp.
References d.
| VCubicBezierPath VCubicBezierPath::Flip | ( | const QLineF & | axis, |
| const QString & | prefix = QString() |
||
| ) | const |
Definition at line 129 of file vcubicbezierpath.cpp.
References append(), GetCubicPath(), VAbstractCurve::getLineColor(), VAbstractCurve::getLineWeight(), VAbstractCurve::GetPenStyle(), VGObject::name(), VAbstractCurve::setLineColor(), VAbstractCurve::setLineWeight(), VGObject::setName(), and VAbstractCurve::SetPenStyle().
|
virtual |
Implements VAbstractBezier.
Definition at line 262 of file vcubicbezierpath.cpp.
References CountSubSpl(), VSpline::GetC1Length(), and GetSpline().
|
virtual |
Implements VAbstractBezier.
Definition at line 275 of file vcubicbezierpath.cpp.
References CountSubSpl(), VSpline::GetC2Length(), and GetSpline().
Definition at line 318 of file vcubicbezierpath.cpp.
References d.
Referenced by Flip(), Move(), VisToolCubicBezierPath::RefreshGeometry(), and Rotate().
|
virtual |
Implements VAbstractCurve.
Definition at line 248 of file vcubicbezierpath.cpp.
References CountSubSpl(), VSpline::GetEndAngle(), and GetSpline().
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 204 of file vcubicbezierpath.cpp.
References CountPoints(), CountSubSpl(), d, and SubSplOffset().
Referenced by GetC1Length(), GetC2Length(), GetEndAngle(), GetSplinePath(), GetStartAngle(), and VisToolCubicBezierPath::RefreshGeometry().
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 289 of file vcubicbezierpath.cpp.
References CountSubSpl(), VSpline::GetC1Length(), VSpline::GetC1LengthFormula(), VSpline::GetC2Length(), VSpline::GetC2LengthFormula(), VSpline::GetEndAngle(), VSpline::GetEndAngleFormula(), VSpline::GetP1(), VSpline::GetP4(), GetSpline(), VSpline::GetStartAngle(), VSpline::GetStartAngleFormula(), VSplinePoint::SetAngle1(), VSplinePoint::SetAngle2(), VSplinePoint::SetLength1(), VSplinePoint::SetLength2(), and VSplinePoint::SetP().
|
virtual |
Implements VAbstractCurve.
Definition at line 235 of file vcubicbezierpath.cpp.
References CountSubSpl(), GetSpline(), and VSpline::GetStartAngle().
|
virtual |
Implements VAbstractCubicBezierPath.
Definition at line 369 of file vcubicbezierpath.cpp.
References CountSubSpl(), d, and SubSplOffset().
| VCubicBezierPath VCubicBezierPath::Move | ( | qreal | length, |
| qreal | angle, | ||
| const QString & | prefix = QString() |
||
| ) | const |
Definition at line 145 of file vcubicbezierpath.cpp.
References append(), GetCubicPath(), VAbstractCurve::getLineColor(), VAbstractCurve::getLineWeight(), VAbstractCurve::GetPenStyle(), VGObject::name(), VAbstractCurve::setLineColor(), VAbstractCurve::setLineWeight(), VGObject::setName(), and VAbstractCurve::SetPenStyle().
| VCubicBezierPath & VCubicBezierPath::operator= | ( | const VCubicBezierPath & | curve | ) |
Definition at line 101 of file vcubicbezierpath.cpp.
References d, and VAbstractCurve::operator=().
| VPointF & VCubicBezierPath::operator[] | ( | int | indx | ) |
Definition at line 166 of file vcubicbezierpath.cpp.
References d.
| VCubicBezierPath VCubicBezierPath::Rotate | ( | const QPointF & | originPoint, |
| qreal | degrees, | ||
| const QString & | prefix = QString() |
||
| ) | const |
Definition at line 113 of file vcubicbezierpath.cpp.
References append(), GetCubicPath(), VAbstractCurve::getLineColor(), VAbstractCurve::getLineWeight(), VAbstractCurve::GetPenStyle(), VGObject::name(), VAbstractCurve::setLineColor(), VAbstractCurve::setLineWeight(), VGObject::setName(), and VAbstractCurve::SetPenStyle().
|
static |
Definition at line 334 of file vcubicbezierpath.cpp.
Referenced by DialogCubicBezierPath::AllPathBackboneIds(), GetSpline(), LastPoint(), and VisToolCubicBezierPath::RefreshGeometry().
|
static |
Definition at line 345 of file vcubicbezierpath.cpp.
Referenced by VisToolCubicBezierPath::Creating(), VisToolCubicBezierPath::RefreshToolTip(), and DialogCubicBezierPath::ShowDialog().
| void VCubicBezierPath::Swap | ( | VCubicBezierPath & | curve | ) |
Definition at line 69 of file vcubicbezierpath.cpp.
References VAbstractCurve::Swap().
|
private |
Definition at line 114 of file vcubicbezierpath.h.
Referenced by append(), at(), Clear(), CountPoints(), CountSubSpl(), FirstPoint(), GetCubicPath(), GetSpline(), LastPoint(), operator=(), operator[](), and VCubicBezierPath().