#include <DbLoftOptions.h>
|
| OdDbLoftOptions () |
|
| OdDbLoftOptions (const OdDbLoftOptions &src) |
|
| ~OdDbLoftOptions () |
|
OdDbLoftOptions & | operator= (const OdDbLoftOptions &rhs) |
|
double | draftStart () const |
|
void | setDraftStart (double angle) |
|
double | draftEnd () const |
|
void | setDraftEnd (double angle) |
|
double | draftStartMag () const |
|
void | setDraftStartMag (double startMag) |
|
double | draftEndMag () const |
|
void | setDraftEndMag (double val) |
|
bool | arcLengthParam () const |
|
void | setArcLengthParam (bool alParam) |
|
bool | noTwist () const |
|
void | setNoTwist (bool noTwist) |
|
bool | alignDirection () const |
|
void | setAlignDirection (bool alignDir) |
|
bool | simplify () const |
|
void | setSimplify (bool simplify) |
|
bool | closed () const |
|
void | setClosed (bool closed) |
|
bool | ruled () const |
|
void | setRuled (bool ruled) |
|
bool | virtualGuide () const |
|
void | setVirtualGuide (bool virtGuide) |
|
OdDbLoftOptions::NormalOption | normal () const |
|
void | setNormal (OdDbLoftOptions::NormalOption option) |
|
OdResult | setOptionsFromSysvars (const OdDbDatabase &pDb) |
|
OdResult | setSysvarsFromOptions (OdDbDatabase &pDb) |
|
OdResult | checkOptions (bool displayErrorMessages=false) |
|
OdResult | checkLoftCurves (OdDbEntityPtrArray &crossSectionCurves, OdDbEntityPtrArray &guideCurves, OdDbEntity *pPathCurve, bool &allOpen, bool &allClosed, bool &allPlanar, bool displayErrorMessages=false) |
|
OdResult | checkCrossSectionCurves (OdDbEntityPtrArray &crossSectionCurves, bool &allOpen, bool &allClosed, bool &allPlanar, bool displayErrorMessages=false) |
|
OdResult | checkGuideCurves (OdDbEntityPtrArray &guideCurves, bool displayErrorMessages=false) |
|
OdResult | checkPathCurve (OdDbEntity *pPathCurve, bool displayErrorMessages=false) |
|
Class for setting options used for creating lofted surfaces and lofted solids (by calling OdDbLoftedSurface::createLoftedSurface() or OdDb3dSolid::createLoftedSolid() methods). Loft options are used to control the shape of the resulting surface or solid object.
<group OdDb_Classes>
Definition at line 40 of file DbLoftOptions.h.
◆ NormalOption
Enumeration for specifying plane normal lofting regimes.
Enumerator |
---|
kNoNormal | Plane normal lofting is off: surface direction is calculated at each cross-section.
|
kFirstNormal | Direction of the surface at the first cross-section will be the same as the plane normal of the cross-section.
|
kLastNormal | Direction of the surface at the last cross-section will be the same as the plane normal of the cross-section.
|
kEndsNormal | Direction of the surface at the first and last cross-sections will be the same as the plane normal of the cross-section.
|
kAllNormal | Direction of the surface at each cross-section will be the same as the plane normal of the cross-section.
|
kUseDraftAngles | Direction of the surface at each cross-section will be the same as the plane normal of the cross-section.
|
Definition at line 68 of file DbLoftOptions.h.
◆ OdDbLoftOptions() [1/2]
OdDbLoftOptions::OdDbLoftOptions |
( |
| ) |
|
◆ OdDbLoftOptions() [2/2]
◆ ~OdDbLoftOptions()
OdDbLoftOptions::~OdDbLoftOptions |
( |
| ) |
|
◆ alignDirection()
bool OdDbLoftOptions::alignDirection |
( |
| ) |
const |
Returns the value of the direction alignment flag.
THe direction alignment flag is used to orient each of the cross sections so that the normal vector of each cross section points towards the next cross section. The default value is true. If the cross sections are not all oriented in the same direction, then this flag should be used to avoid creating a twisted or self-intersecting surface.
◆ arcLengthParam()
bool OdDbLoftOptions::arcLengthParam |
( |
| ) |
const |
Returns the flag determining whether arc length parameterization is applied.
◆ checkCrossSectionCurves()
OdResult OdDbLoftOptions::checkCrossSectionCurves |
( |
OdDbEntityPtrArray & |
crossSectionCurves, |
|
|
bool & |
allOpen, |
|
|
bool & |
allClosed, |
|
|
bool & |
allPlanar, |
|
|
bool |
displayErrorMessages = false |
|
) |
| |
Checks whether cross section curves are valid for the lofting operation.
- Parameters
-
crossSectionCurves | [in] A list of cross-section curves. |
allOpen | [out] A passed-in parameter indicating whether all of the cross-section curves are open. |
allClosed | [out] A passed-in parameter indicating whether all of the cross-section curves are closed. |
allPlanar | [out] A passed-in parameter indicating whether all of the cross-section curves are planar. |
displayErrorMessages | [in] Indicates whether error messages are displayed. Default value is false. |
- Returns
- Returns eOk if curves are valid or eInvalidInput otherwise.
◆ checkGuideCurves()
Checks whether guide curves are valid for the lofting operation.
- Parameters
-
guideCurves | [in] A list of guide curves. |
displayErrorMessages | [in] Indicates whether error messages are displayed. Default value is false. |
- Returns
- Returns eOk if guide curves are valid or eInvalidInput otherwise.
◆ checkLoftCurves()
Checks whether cross section curves and path curves are valid for the lofting operation.
- Parameters
-
crossSectionCurves | [in] A list of cross-section curves. |
guideCurves | [in] A list of guide curves. |
pPathCurve | [in] A pointer to a path curve (can be NULL). |
allOpen | [out] A passed-in parameter indicating whether all of the cross-section curves are open. |
allClosed | [out] A passed-in parameter indicating whether all of the cross-section curves are closed. |
allPlanar | [out] A passed-in parameter indicating whether all of the cross-section curves are planar. |
displayErrorMessages | [in] Indicates whether error messages are displayed. Default value is false. |
- Returns
- Returns eOk if curves are valid or eInvalidInput otherwise.
◆ checkOptions()
OdResult OdDbLoftOptions::checkOptions |
( |
bool |
displayErrorMessages = false | ) |
|
Validates the loft options values.
- Parameters
-
displayErrorMessages | [in] Indicates whether error messages are displayed. Default value is false. |
- Returns
- Returns eOk if the options values are all valid.
◆ checkPathCurve()
Checks whether a path curve is valid for the lofting operation.
- Parameters
-
pPathCurve | [in] A pointer to the path curve (can be NULL). |
displayErrorMessages | [in] Indicates whether error messages are displayed. Default value is false. |
- Returns
- Returns eOk if a path curve is valid or eInvalidInput otherwise.
◆ closed()
bool OdDbLoftOptions::closed |
( |
| ) |
const |
Returns the value of the closed flag.
If the closed flag is set to true, the created surface starts and ends at the first cross section (i.e. the surface is closed). If all of the cross sections are closed, the resulting surface takes a torus-like shape. If the closed flag is set to false, the surface is opened or capped with a planar surface at the first and last cross sections. If the flag is set, then there must be at least three cross sections.
The default value is false.
◆ draftEnd()
double OdDbLoftOptions::draftEnd |
( |
| ) |
const |
Returns the end draft angle in radians. This is the surface take-off direction at the last cross section. The default value is 0; no draft angle is applied and the optimum angle is calculated at the last cross section.
◆ draftEndMag()
double OdDbLoftOptions::draftEndMag |
( |
| ) |
const |
Returns the end draft magnitude.
The value returned by the method determines the magnitude of the surface tangent vector at the last cross-section. The default value is 0; the optimum magnitude is calculated at the last cross section.
◆ draftStart()
double OdDbLoftOptions::draftStart |
( |
| ) |
const |
Returns the start draft angle in radians. This is the surface take-off direction at the first cross section. The default value is 0; no draft angle is applied and the optimum angle is calculated at the first cross section.
◆ draftStartMag()
double OdDbLoftOptions::draftStartMag |
( |
| ) |
const |
Returns the start draft magnitude. The value returned by the method determines the magnitude of the surface tangent vector at the first cross-section. The default value is 0; the optimum magnitude is calculated at the last cross section.
◆ normal()
Returns the plane normal flag.
The default value of the flag is kNoNormal.
◆ noTwist()
bool OdDbLoftOptions::noTwist |
( |
| ) |
const |
Returns the flag determining whether the noTwist option is applied. THe option noTwist can be used to minimize the amount of twist in the surface when the cross-sections are all closed. The default value is true; the start point of each closed cross-section is aligned with the other cross-sections to minimize twist.
◆ operator=()
Assigns to the OdDbLoftOptions object another object (assignment operator).
- Parameters
-
◆ ruled()
bool OdDbLoftOptions::ruled |
( |
| ) |
const |
Returns the value of the ruled flag.
If the flag is set to true, a ruled surface will be created between each pair of cross sections, which leads to a coarser surface.
If the flag is set to false, then a single smooth surface is created. The default value is false.
◆ setAlignDirection()
void OdDbLoftOptions::setAlignDirection |
( |
bool |
alignDir | ) |
|
Sets the value of the direction alignment flag.
The direction alignment flag is used to orient each of the cross sections so that the normal vector of each cross section points towards the next cross section. The default value is true. If the cross sections are not all oriented in the same direction, then this flag should be used to avoid creating a twisted or self-intersecting surface.
- Parameters
-
alignDir | [in] A new value of the direction alignment flag. |
◆ setArcLengthParam()
void OdDbLoftOptions::setArcLengthParam |
( |
bool |
alParam | ) |
|
Sets the flag determining whether arc length parameterization is applied.
- Parameters
-
alParam | [in] A new value of the arc length parameterizaton flag. |
◆ setClosed()
void OdDbLoftOptions::setClosed |
( |
bool |
closed | ) |
|
Sets the value of the closed flag.
If the closed flag is set to true, the created surface starts and ends at the first cross section (i.e. the surface is closed). If all of the cross sections are closed, the resulting surface takes a torus-like shape. If the closed flag is set to false, the surface is opened or capped with a planar surface at the first and last cross sections. If the flag is set, then there must be at least three cross sections.
The default value is false.
- Parameters
-
closed | [in] A new value of the closed flag. |
◆ setDraftEnd()
void OdDbLoftOptions::setDraftEnd |
( |
double |
angle | ) |
|
Sets the end draft angle. This is the surface take-off direction at the last cross section. The default value is 0; no draft angle is applied and the optimum angle is calculated at the last cross section.
- Parameters
-
angle | [in] A new value of the end draft angle (radians). |
◆ setDraftEndMag()
void OdDbLoftOptions::setDraftEndMag |
( |
double |
val | ) |
|
Sets the end draft magnitude.
The value set by the method determines the magnitude of the surface tangent vector at the last cross-section. The default value is 0; the optimum magnitude is calculated at the last cross section.
- Parameters
-
startMag | [in] A new value of the end draft magnitude. |
◆ setDraftStart()
void OdDbLoftOptions::setDraftStart |
( |
double |
angle | ) |
|
Sets the start draft angle. This is the surface take-off direction at the first cross section. The default value is 0; no draft angle is applied and the optimum angle is calculated at the first cross section.
- Parameters
-
angle | [in] A new value of the start draft angle (radians). |
◆ setDraftStartMag()
void OdDbLoftOptions::setDraftStartMag |
( |
double |
startMag | ) |
|
Sets the start draft magnitude. The value set by the method determines the magnitude of the surface tangent vector at the first cross-section. The default value is 0; the optimum magnitude is calculated at the last cross section.
- Parameters
-
startMag | [in] A new value of the start draft magnitude. |
◆ setNormal()
Sets the plane normal flag. The default value of the flag is kNoNormal.
- Parameters
-
option | [in] A new value of the plane normal flag. |
◆ setNoTwist()
void OdDbLoftOptions::setNoTwist |
( |
bool |
noTwist | ) |
|
Sets the flag determining whether the noTwist option is applied. The option noTwist can be used due to minimize the amount of twist in the surface when the cross-sections are all closed. The default value is true; the start point of each closed cross-section is aligned with the other cross-sections to minimize twist.
- Parameters
-
noTwist | [in] A new value of noTwist flag. |
◆ setOptionsFromSysvars()
Sets loft options from the current values of system variables.
- Parameters
-
pDb | [in] A reference to a database object that is used to get access to system variable values. |
- Returns
- Returns eOk if options were successfully set or an appropriate error otherwise.
◆ setRuled()
void OdDbLoftOptions::setRuled |
( |
bool |
ruled | ) |
|
Sets the value of the ruled flag.
If the flag is set to true, a ruled surface will be created between each pair of cross sections, which leads to a coarser surface.
If the flag is set to false, then a single smooth surface is created. The default value is false.
- Parameters
-
ruled | [in] A new value of the ruled flag. |
◆ setSimplify()
void OdDbLoftOptions::setSimplify |
( |
bool |
simplify | ) |
|
Sets the value of the simplify flag.
If the simplify flag is set to true, simple surface types (such as plane, cylinder, cone, sphere and torus) are created whenever all of the cross sections lie on such a surface. If the simplify flag is set to false, a general surface type will be created. The default value is true.
- Parameters
-
simplify | [in] A new value of the simplify flag. |
◆ setSysvarsFromOptions()
Sets the system variables values from loft options values.
- Parameters
-
pDb | [out] A reference to a database object that is used to change system variables values. |
- Returns
- Returns eOk if system variables were successfully set or an appropriate error otherwise.
◆ setVirtualGuide()
void OdDbLoftOptions::setVirtualGuide |
( |
bool |
virtGuide | ) |
|
Sets the virtual guide flag.
- Parameters
-
virtGuide | [in] A new value of the virtual guide flag. |
◆ simplify()
bool OdDbLoftOptions::simplify |
( |
| ) |
const |
Returns the value of the simplify flag. If the simplify flag is set to true, simple surface types (such as plane, cylinder, cone, sphere and torus) are created whenever all of the cross sections lie on such a surface. If the simplify flag is set to false, a general surface type will be created. The default value is true.
◆ virtualGuide()
bool OdDbLoftOptions::virtualGuide |
( |
| ) |
const |
Returns the virtual guide option.
◆ OdDbLoftOptionsImpl
friend class OdDbLoftOptionsImpl |
|
friend |
The documentation for this class was generated from the following file: