RSplineEntity
Class in Entity Module
Header: #include <src/entity/RSplineEntity.h>
Inherits: REntity
Description
Section titled “Description”Spline entity.
Scriptable: This class is available in script environments.
Shared Pointer Support: Objects can be used in QSharedPointer.
Public Functions
Section titled “Public Functions”RSplineEntity(const RSplineEntity &other) |
|
RSplineEntity(RDocument *document, const RSplineData &data) |
|
| virtual | ~RSplineEntity() |
| void | appendControlPoint(const RVector &point) |
| void | appendFitPoint(const RVector &point) |
| RPolyline | approximateWithArcs(double tolerance, double radiusLimit=RDEFAULT_MIN1) const |
| virtual QSharedPointer< RObject > | clone() const |
| QSharedPointer< RSplineEntity > | cloneToSplineEntity() const |
| int | countControlPoints() const |
| int | countFitPoints() const |
| virtual void | exportEntity(RExporter &e, bool preview=false, bool forceSelected=false) constExports the entity to the given exporter. |
| QList< double > | getActualKnotVector() const |
| double | getAngleAt(double distance, RS::From from=RS::FromStart) const |
| QList< RSpline > | getBezierSegments(const RBox &queryBox=RDEFAULT_RBOX) const |
| virtual int | getComplexity() const |
| RVector | getControlPointAt(int i) const |
| QList< RVector > | getControlPoints() const |
| QList< RVector > | getControlPointsWrapped() const |
| virtual RSplineData & | getData() |
| virtual const RSplineData & | getData() const |
| int | getDegree() const |
| double | getDirection1() const |
| double | getDirection2() const |
| RVector | getEndPoint() const |
| QList< QSharedPointer< RShape > > | getExploded(int segments=RDEFAULT_MIN1) const |
| RVector | getFitPointAt(int i) const |
| QList< RVector > | getFitPoints() const |
| QList< double > | getKnotVector() const |
| double | getLength() const |
| RVector | getPointAt(double t) const |
| RVector | getPointAtDistance(double distance) const |
| virtual QPair< QVariant, RPropertyAttributes > | getProperty(RPropertyTypeId &propertyTypeId, bool humanReadable=false, bool noAttributes=false, bool showOnRequest=false) |
| RS::Side | getSideOfPoint(const RVector &point) const |
| RVector | getStartPoint() const |
| RVector | getTangentAtEnd() const |
| RVector | getTangentAtStart() const |
| double | getTAtDistance(double distance) const |
| double | getTAtPoint(const RVector &point) const |
| double | getTDelta() const |
| double | getTMax() const |
| double | getTMin() const |
| RS::Ending | getTrimEnd(const RVector &trimPoint, const RVector &clickPoint) |
| QList< double > | getWeights() const |
| bool | hasFitPoints() const |
| void | insertFitPointAt(const RVector &point) |
| bool | isClosed() const |
| bool | isGeometricallyClosed(double tolerance=RS::PointTolerance) const |
| bool | isPeriodic() const |
| virtual bool | isValid() const |
| void | prependFitPoint(const RVector &point) |
| void | removeFitPointAt(const RVector &point) |
| bool | reverse() |
| void | setEndPoint(const RVector &ep) |
| void | setPeriodic(bool on) |
| virtual bool | setProperty(RPropertyTypeId propertyTypeId, const QVariant &value, RTransaction *transaction=NULL)Sets the given property to the given value. |
| void | setShape(const RSpline &s) |
| void | setStartPoint(const RVector &sp) |
| virtual void | setUndone(bool on) |
| void | simplify(double tolerance) |
| QList< RSpline > | splitAtParams(const QList< double > ¶ms) const |
| QList< RSpline > | splitAtPoints(const QList< RVector > &points) const |
| RPolyline | toPolyline(int segments) const |
| bool | trimEndPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false) |
| bool | trimStartPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false) |
Static Public Functions
Section titled “Static Public Functions”| static RS::EntityType | getRtti() |
| static QSet< RPropertyTypeId > | getStaticPropertyTypeIds() |
| static void | init() |
Static Public Attributes
Section titled “Static Public Attributes”Protected Functions
Section titled “Protected Functions”| virtual void | print(QDebug dbg) constStream operator for QDebug. |
Protected Attributes
Section titled “Protected Attributes”| RSplineData | data |
Member Documentation
Section titled “Member Documentation”RSplineEntity
Section titled “RSplineEntity”RSplineEntity::RSplineEntity(const RSplineEntity &other)RSplineEntity
Section titled “RSplineEntity”RSplineEntity::RSplineEntity(RDocument *document, const RSplineData &data)~RSplineEntity
Section titled “~RSplineEntity”virtual RSplineEntity::~RSplineEntity()virtual
appendControlPoint
Section titled “appendControlPoint”void RSplineEntity::appendControlPoint(const RVector &point)inline
appendFitPoint
Section titled “appendFitPoint”void RSplineEntity::appendFitPoint(const RVector &point)inline
approximateWithArcs
Section titled “approximateWithArcs”RPolyline RSplineEntity::approximateWithArcs(double tolerance, double radiusLimit=RDEFAULT_MIN1) constinline const
virtual QSharedPointer< RObject > RSplineEntity::clone() constvirtual inline const
Reimplemented from clone.
cloneToSplineEntity
Section titled “cloneToSplineEntity”QSharedPointer< RSplineEntity > RSplineEntity::cloneToSplineEntity() constinline const
countControlPoints
Section titled “countControlPoints”int RSplineEntity::countControlPoints() constinline const
countFitPoints
Section titled “countFitPoints”int RSplineEntity::countFitPoints() constinline const
exportEntity
Section titled “exportEntity”virtual void RSplineEntity::exportEntity(RExporter &e, bool preview=false, bool forceSelected=false) constvirtual const
Exports the entity to the given exporter.
The exporter might be a file exporter, a graphics scene or any other platform one can export entities to.
Reimplemented from exportEntity.
getActualKnotVector
Section titled “getActualKnotVector”QList< double > RSplineEntity::getActualKnotVector() constinline const
getAngleAt
Section titled “getAngleAt”double RSplineEntity::getAngleAt(double distance, RS::From from=RS::FromStart) constinline const
getBezierSegments
Section titled “getBezierSegments”QList< RSpline > RSplineEntity::getBezierSegments(const RBox &queryBox=RDEFAULT_RBOX) constinline const
getComplexity
Section titled “getComplexity”virtual int RSplineEntity::getComplexity() constvirtual const
Reimplemented from getComplexity.
getControlPointAt
Section titled “getControlPointAt”RVector RSplineEntity::getControlPointAt(int i) constinline const
getControlPoints
Section titled “getControlPoints”QList< RVector > RSplineEntity::getControlPoints() constinline const
getControlPointsWrapped
Section titled “getControlPointsWrapped”QList< RVector > RSplineEntity::getControlPointsWrapped() constinline const
getData
Section titled “getData”virtual RSplineData & RSplineEntity::getData()virtual inline
Returns: Reference to the data object of the entity.
Reimplemented from getData.
getData
Section titled “getData”virtual const RSplineData & RSplineEntity::getData() constvirtual inline const
Returns: Const reference to the data object of the entity.
Reimplemented from getData.
getDegree
Section titled “getDegree”int RSplineEntity::getDegree() constinline const
getDirection1
Section titled “getDirection1”double RSplineEntity::getDirection1() constinline const
getDirection2
Section titled “getDirection2”double RSplineEntity::getDirection2() constinline const
getEndPoint
Section titled “getEndPoint”RVector RSplineEntity::getEndPoint() constinline const
getExploded
Section titled “getExploded”QList< QSharedPointer< RShape > > RSplineEntity::getExploded(int segments=RDEFAULT_MIN1) constinline const
getFitPointAt
Section titled “getFitPointAt”RVector RSplineEntity::getFitPointAt(int i) constinline const
getFitPoints
Section titled “getFitPoints”QList< RVector > RSplineEntity::getFitPoints() constinline const
getKnotVector
Section titled “getKnotVector”QList< double > RSplineEntity::getKnotVector() constinline const
getLength
Section titled “getLength”double RSplineEntity::getLength() constinline const
getPointAt
Section titled “getPointAt”RVector RSplineEntity::getPointAt(double t) constinline const
getPointAtDistance
Section titled “getPointAtDistance”RVector RSplineEntity::getPointAtDistance(double distance) constinline const
getProperty
Section titled “getProperty”virtual QPair< QVariant, RPropertyAttributes > RSplineEntity::getProperty(RPropertyTypeId &propertyTypeId, bool humanReadable=false, bool noAttributes=false, bool showOnRequest=false)virtual
Returns: The value and attributes of the given property or an invalid property if this property owner has no property with the given ID.
Reimplemented from getProperty.
getSideOfPoint
Section titled “getSideOfPoint”RS::Side RSplineEntity::getSideOfPoint(const RVector &point) constinline const
getStartPoint
Section titled “getStartPoint”RVector RSplineEntity::getStartPoint() constinline const
getTangentAtEnd
Section titled “getTangentAtEnd”RVector RSplineEntity::getTangentAtEnd() constinline const
getTangentAtStart
Section titled “getTangentAtStart”RVector RSplineEntity::getTangentAtStart() constinline const
getTAtDistance
Section titled “getTAtDistance”double RSplineEntity::getTAtDistance(double distance) constinline const
getTAtPoint
Section titled “getTAtPoint”double RSplineEntity::getTAtPoint(const RVector &point) constinline const
getTDelta
Section titled “getTDelta”double RSplineEntity::getTDelta() constinline const
getTMax
Section titled “getTMax”double RSplineEntity::getTMax() constinline const
getTMin
Section titled “getTMin”double RSplineEntity::getTMin() constinline const
getTrimEnd
Section titled “getTrimEnd”RS::Ending RSplineEntity::getTrimEnd(const RVector &trimPoint, const RVector &clickPoint)inline
getWeights
Section titled “getWeights”QList< double > RSplineEntity::getWeights() constinline const
hasFitPoints
Section titled “hasFitPoints”bool RSplineEntity::hasFitPoints() constinline const
insertFitPointAt
Section titled “insertFitPointAt”void RSplineEntity::insertFitPointAt(const RVector &point)inline
isClosed
Section titled “isClosed”bool RSplineEntity::isClosed() constinline const
isGeometricallyClosed
Section titled “isGeometricallyClosed”bool RSplineEntity::isGeometricallyClosed(double tolerance=RS::PointTolerance) constinline const
isPeriodic
Section titled “isPeriodic”bool RSplineEntity::isPeriodic() constinline const
isValid
Section titled “isValid”virtual bool RSplineEntity::isValid() constvirtual inline const
Reimplemented from isValid.
prependFitPoint
Section titled “prependFitPoint”void RSplineEntity::prependFitPoint(const RVector &point)inline
removeFitPointAt
Section titled “removeFitPointAt”void RSplineEntity::removeFitPointAt(const RVector &point)inline
reverse
Section titled “reverse”bool RSplineEntity::reverse()inline
setEndPoint
Section titled “setEndPoint”void RSplineEntity::setEndPoint(const RVector &ep)inline
setPeriodic
Section titled “setPeriodic”void RSplineEntity::setPeriodic(bool on)inline
setProperty
Section titled “setProperty”virtual bool RSplineEntity::setProperty(RPropertyTypeId propertyTypeId, const QVariant &value, RTransaction *transaction=NULL)virtual
Sets the given property to the given value.
If this property owner does not know a property with that ID, it is up to the property owner what happens. The property might be added into a list of dynamic properties or dropped.
Returns: True if the property owner was modified in any way, false otherwise.
Reimplemented from setProperty.
setShape
Section titled “setShape”void RSplineEntity::setShape(const RSpline &s)setStartPoint
Section titled “setStartPoint”void RSplineEntity::setStartPoint(const RVector &sp)inline
setUndone
Section titled “setUndone”virtual void RSplineEntity::setUndone(bool on)virtual inline
simplify
Section titled “simplify”void RSplineEntity::simplify(double tolerance)inline
splitAtParams
Section titled “splitAtParams”QList< RSpline > RSplineEntity::splitAtParams(const QList< double > ¶ms) constinline const
splitAtPoints
Section titled “splitAtPoints”QList< RSpline > RSplineEntity::splitAtPoints(const QList< RVector > &points) constinline const
toPolyline
Section titled “toPolyline”RPolyline RSplineEntity::toPolyline(int segments) constinline const
trimEndPoint
Section titled “trimEndPoint”bool RSplineEntity::trimEndPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)inline
trimStartPoint
Section titled “trimStartPoint”bool RSplineEntity::trimStartPoint(const RVector &trimPoint, const RVector &clickPoint=RVector::invalid, bool extend=false)inline
getRtti
Section titled “getRtti”static RS::EntityType RSplineEntity::getRtti()static inline
getStaticPropertyTypeIds
Section titled “getStaticPropertyTypeIds”static QSet< RPropertyTypeId > RSplineEntity::getStaticPropertyTypeIds()static inline
static void RSplineEntity::init()static
PropertyBlock
Section titled “PropertyBlock”static RPropertyTypeId RSplineEntity::PropertyBlockstatic
PropertyColor
Section titled “PropertyColor”static RPropertyTypeId RSplineEntity::PropertyColorstatic
PropertyControlPointNX
Section titled “PropertyControlPointNX”static RPropertyTypeId RSplineEntity::PropertyControlPointNXstatic
PropertyControlPointNY
Section titled “PropertyControlPointNY”static RPropertyTypeId RSplineEntity::PropertyControlPointNYstatic
PropertyControlPointNZ
Section titled “PropertyControlPointNZ”static RPropertyTypeId RSplineEntity::PropertyControlPointNZstatic
PropertyCustom
Section titled “PropertyCustom”static RPropertyTypeId RSplineEntity::PropertyCustomstatic
All rights reserved.
This file is part of the QCAD project.
QCAD is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
QCAD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with QCAD.
PropertyDegree
Section titled “PropertyDegree”static RPropertyTypeId RSplineEntity::PropertyDegreestatic
PropertyDisplayedColor
Section titled “PropertyDisplayedColor”static RPropertyTypeId RSplineEntity::PropertyDisplayedColorstatic
PropertyDrawOrder
Section titled “PropertyDrawOrder”static RPropertyTypeId RSplineEntity::PropertyDrawOrderstatic
PropertyEndTangentX
Section titled “PropertyEndTangentX”static RPropertyTypeId RSplineEntity::PropertyEndTangentXstatic
PropertyEndTangentY
Section titled “PropertyEndTangentY”static RPropertyTypeId RSplineEntity::PropertyEndTangentYstatic
PropertyEndTangentZ
Section titled “PropertyEndTangentZ”static RPropertyTypeId RSplineEntity::PropertyEndTangentZstatic
PropertyFitPointNX
Section titled “PropertyFitPointNX”static RPropertyTypeId RSplineEntity::PropertyFitPointNXstatic
PropertyFitPointNY
Section titled “PropertyFitPointNY”static RPropertyTypeId RSplineEntity::PropertyFitPointNYstatic
PropertyFitPointNZ
Section titled “PropertyFitPointNZ”static RPropertyTypeId RSplineEntity::PropertyFitPointNZstatic
PropertyHandle
Section titled “PropertyHandle”static RPropertyTypeId RSplineEntity::PropertyHandlestatic
PropertyKnotN
Section titled “PropertyKnotN”static RPropertyTypeId RSplineEntity::PropertyKnotNstatic
PropertyLayer
Section titled “PropertyLayer”static RPropertyTypeId RSplineEntity::PropertyLayerstatic
PropertyLength
Section titled “PropertyLength”static RPropertyTypeId RSplineEntity::PropertyLengthstatic
PropertyLinetype
Section titled “PropertyLinetype”static RPropertyTypeId RSplineEntity::PropertyLinetypestatic
PropertyLinetypeScale
Section titled “PropertyLinetypeScale”static RPropertyTypeId RSplineEntity::PropertyLinetypeScalestatic
PropertyLineweight
Section titled “PropertyLineweight”static RPropertyTypeId RSplineEntity::PropertyLineweightstatic
PropertyPeriodic
Section titled “PropertyPeriodic”static RPropertyTypeId RSplineEntity::PropertyPeriodicstatic
PropertyProtected
Section titled “PropertyProtected”static RPropertyTypeId RSplineEntity::PropertyProtectedstatic
PropertyStartTangentX
Section titled “PropertyStartTangentX”static RPropertyTypeId RSplineEntity::PropertyStartTangentXstatic
PropertyStartTangentY
Section titled “PropertyStartTangentY”static RPropertyTypeId RSplineEntity::PropertyStartTangentYstatic
PropertyStartTangentZ
Section titled “PropertyStartTangentZ”static RPropertyTypeId RSplineEntity::PropertyStartTangentZstatic
PropertyTotalLength
Section titled “PropertyTotalLength”static RPropertyTypeId RSplineEntity::PropertyTotalLengthstatic
PropertyType
Section titled “PropertyType”static RPropertyTypeId RSplineEntity::PropertyTypestatic
PropertyUseEndTangent
Section titled “PropertyUseEndTangent”static RPropertyTypeId RSplineEntity::PropertyUseEndTangentstatic
PropertyUseStartTangent
Section titled “PropertyUseStartTangent”static RPropertyTypeId RSplineEntity::PropertyUseStartTangentstatic
PropertyWorkingSet
Section titled “PropertyWorkingSet”static RPropertyTypeId RSplineEntity::PropertyWorkingSetstatic
virtual void RSplineEntity::print(QDebug dbg) constvirtual const protected
Stream operator for QDebug.
Reimplemented from print.
RSplineData RSplineEntity::dataprotected