|
NX Open C++ 参考指南 2406 v1.1
|
草图对象 更多...
#include <Sketch.hxx>
类 | |
| struct | ConstraintGeometry |
| struct | ConstraintGeometryHelp |
| struct | CopyObjectData |
| struct | DimensionGeometry |
| struct | SketchGeometry |
友元 | |
| class | _SketchBuilder |
额外继承的成员函数 | |
| Public 属性 继承自 NXOpen::NXObject | |
| NXOpen::Update::Option | option |
| const NXString NXOpen::Update::Option | option |
| double NXOpen::Update::Option | option |
| int NXOpen::Update::Option | option |
| const NXString & | value |
| double | value |
| int | value |
草图对象
表示草图
使用 NXOpen::SketchCollection 类创建草图。
创建于 NX3.0.0。
Used by NXOpen::Sketch::AddGeometry to determine whether to treat an ellipse as an ellipse or generic conic when adding the curve to a sketch. Treating an ellipse as a conic means that the ellipse will be given an anchor point. This affects, among other things, how the ellipse behaves when it is dragged. In order for an ellipse to be treated as a conic, its end angle minus its start angle must be less than 180 degrees.
| 枚举值 | |
|---|---|
| AddEllipseOptionTreatAsEllipse | treat as ellipse |
| AddEllipseOptionTreatAsConic | treat as conic |
Used in NXOpen::Sketch::DimensionGeometry to indicate what type of geometry to use
Type of Auto Dimensioning rules. It should match the rule types defined in Auto Dimensioning engine. Auto Dimensioning rules affect how the dimensions are created by the Auto Dimensioner. The rules will be put in a list, the first the rule with the highest priority and the last rule with the lowest priority. The user can change the order of the rules in the list to persue the flavor of the dimensions he wants. NXOpen::Sketch::AutoDimensioningRuleSymmetric : create symmetric dimensions if the curves are symmetric NXOpen::Sketch::AutoDimensioningRuleAdjacentAngle : create angles between adjacent lines NXOpen::Sketch::AutoDimensioningRuleLength : create length dimension for lines NXOpen::Sketch::AutoDimensioningRuleHorizontalVertical : create horizontal and vertical dimensions NXOpen::Sketch::AutoDimensioningRuleReferenceAxes : create dimensions between curves and reference axes
Represents the class of the constraint. There are two classes of constraints: geometric and dimension
用于在 ConstraintGeometry 中指示几何是什么类型的点(如果有的话)
Represents the type of constraint
Used by NXOpen::Sketch::CreateDimension , NXOpen::Sketch::CreateRadialDimension NXOpen::Sketch::CreateDiameterDimension and NXOpen::Sketch::CreatePerimeterDimension to determine whether to create driving, constant, or reference dimension
Sketch operations can involve an entire geometric object, such as a NXOpen::Line , or a control point of the geometry, such as a start point or center point.
| void NXOpen::Sketch::Activate | ( | NXOpen::Sketch::ViewReorient | orientView | ) |
重新附着草图。
草图将附着到的面或基准平面。必须是平面。 可以是基准轴、边、基准平面、面或 NULL。 如果是边,该边必须是线段。如果是面, 该面必须是平面。如果为 NULL,则使用 reference_direction。 如果 reference_axis 为 NULL, 此参数设置草图的参考方向。 此时,该参数不能为 (0,0,0)。 如果 reference_axis 不为 NULL 且此参数不为 (0,0,0),此参数 确定参考方向是与 reference_axis 同向 还是反向。如果此参数为 (0,0,0), 则不使用此参数。 指示参考轴是水平还是垂直。 除非 reference_direction 为 (0,0,0) 且 reference_axis 是边或基准轴,否则忽略。 此参数指示参考轴应与 reference_axis 同向还是反向。 草图的 Z 轴应向外还是向内。 草图局部坐标系的原点。 Activates the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| orientView | Indicates whether to orient the view to the sketch during activation |
| void NXOpen::Sketch::AddGeometry | ( | NXOpen::Curve * | crv, |
| NXOpen::Sketch::InferConstraintsOption | inferCoincidentConstraints, | ||
| NXOpen::Sketch::AddEllipseOption | ellipseOption ) |
Adds a curve or point to a sketch.
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| crv | Must be a curve or point |
| inferCoincidentConstraints | Whether to automatically create coincident constraints when adding the geometry. If this flag is true and there exists another curve or point in the sketch that has a vertex that is at the same location (within system tolerance) as one of the vertices for crv, a coincident constraint will be created |
| ellipseOption | If you are adding an ellipse to the sketch, this parameter indicates whether the ellipse should be treated as an ellipse or general conic. If you are not adding an ellipse, the option is ignored. See the documentation for NXOpen::Sketch::AddEllipseOption for more details. The default value is NXOpen::Sketch::AddEllipseOptionTreatAsEllipse . In order to treat an ellipse as a conic, its end angle minus its start angle must be less than 180 degrees. |
| void NXOpen::Sketch::AddGeometry | ( | NXOpen::DisplayableObject * | crv | ) |
Adds a curve or point to the sketch. Infers coincident constraints with other geometry in the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| crv | Must be a curve or point |
| void NXOpen::Sketch::AddGeometry | ( | NXOpen::DisplayableObject * | crv, |
| NXOpen::Sketch::InferConstraintsOption | inferCoincidentConstraints ) |
Adds a curve or point to the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| crv | Must be a curve or point |
| inferCoincidentConstraints | Whether to automatically create coincident constraints when adding the geometry. If this flag is true and there exists another curve or point in the sketch that has a vertex that is at the same location (within system tolerance) as one of the vertices for crv, a coincident constraint will be created |
| void NXOpen::Sketch::AddGeometry | ( | NXOpen::Sketch::InferConstraintsOption | inferCoincidentConstraints, |
| NXOpen::Sketch::AddEllipseOption | ellipseOption, | ||
| const std::vector< NXOpen::SmartObject * > & | curvesOrPoints ) |
Adds an array of curves or points to a sketch.
Created in NX6.0.1.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| inferCoincidentConstraints | Whether to automatically create coincident constraints when adding the geometry. If this flag is true and there exists another curve or point in the sketch that has a vertex that is at the same location (within system tolerance) as one of the vertices for crv, a coincident constraint will be created |
| ellipseOption | If you are adding an ellipse to the sketch, this parameter indicates whether the ellipse should be treated as an ellipse or general conic. If you are not adding an ellipse, the option is ignored. See the documentation for NXOpen::Sketch::AddEllipseOption for more details. The default value is NXOpen::Sketch::AddEllipseOptionTreatAsEllipse . In order to treat an ellipse as a conic, its end angle minus its start angle must be less than 180 degrees. |
| curvesOrPoints | Must be a curve or point |
| NXOpen::ISurface * NXOpen::Sketch::AttachPlane | ( | ) |
Returns the plane that the sketch is attached to
Created in NX3.0.0.
License requirements : None
| std::vector< NXOpen::SketchConstraint * > NXOpen::Sketch::AutoConstrain | ( | double | linearTolerance, |
| double | angularTolerance, | ||
| bool | allowRemoteConstraints, | ||
| const std::vector< NXOpen::SmartObject * > & | geometries, | ||
| const std::vector< NXOpen::Sketch::ConstraintType > & | autoconstraintTypes ) |
对输入的几何集创建自动约束。
| linearTolerance | 捕捉距离 |
| angularTolerance | 捕捉角度 |
| allowRemoteConstraints | 是否允许远程约束 |
| geometries | 几何数组 |
| autoconstraintTypes | 约束类型数组 |
| void NXOpen::Sketch::BreakAssociativity | ( | const std::vector< NXOpen::NXObject * > & | sketchGeoms | ) |
断开草图中配方几何(投影或相交曲线和点)的关联性,使其成为常规草图几何。 忽略任何非配方几何。在草图更新前调用。
创建于 NX11.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| sketchGeoms | 活动草图中的配方几何 |
| void NXOpen::Sketch::CalculateStatus | ( | ) |
Calculate the sketch status to detect if the dimensions and persistent relations define the sketch properly. The calculated status is stored on the sketch and can be accessed using NXOpen::Sketch::GetStatus . The sketch should be active without the Work Region enabled to get the correct status.
Created in NX1980.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| void NXOpen::Sketch::ConvertRadialDimension | ( | const std::vector< NXOpen::DisplayableObject * > & | dimensions | ) |
将半径尺寸转换为直径尺寸或直径尺寸转换为半径尺寸。 当尺寸是驱动尺寸且其表达式被其他表达式引用,或其值是引用表达式的公式时,转换将不执行。 转换半径到直径时,半径值加倍为直径值。 转换直径到半径时,直径值减半为半径值。
创建于 NX1899.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| dimensions | 要转换的尺寸 |
| void NXOpen::Sketch::ConvertToNx10Spline | ( | NXOpen::Spline * | spline | ) |
将旧版样条曲线转换为新的 NX10 样条曲线。输入样条曲线将升级为 NX10 样条曲线。不会创建新样条曲线来替换输入样条曲线。
创建于 NX10.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| spline | 样条曲线 |
| std::vector< NXOpen::NXObject * > NXOpen::Sketch::CopyObjects | ( | const std::vector< NXOpen::NXObject * > & | inputObjects | ) |
创建输入对象及其之间约束的副本。
| inputObjects | 要复制的对象 |
| void NXOpen::Sketch::CopyObjectsWithDimensionOutput | ( | const std::vector< NXOpen::NXObject * > & | inputObjects, |
| std::vector< NXOpen::NXObject * > & | outputObjects, | ||
| std::vector< NXOpen::NXObject * > & | outputDims ) |
创建输入对象及其之间约束的副本。此函数与 NXOpen::Sketch::CopyObjects 相同,只是返回新创建的尺寸数组
创建于 NX6.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| inputObjects | 要复制的对象 |
| outputObjects | 副本对象 |
| outputDims | 副本尺寸 |
| std::vector< NXOpen::Sketch::CopyObjectData > NXOpen::Sketch::CopyObjectsWithTracking | ( | const std::vector< NXOpen::DisplayableObject * > & | inputObjects | ) |
复制输入对象和它们之间的约束。 仅当输入对象数组中显式包含时,才复制草图尺寸。
| inputObjects | 要复制的对象 |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateCoincidentConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | geom1, |
| const NXOpen::Sketch::ConstraintGeometry & | geom2 ) |
Creates a coincident constraint
| geom1 | Must be a vertex |
| geom2 | Must be a vertex |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateCollinearConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates a collinear constraint. One of the input constraint geometries must be a line.
| conGeom1 | Must be a line, linear edge, datum axis, or datum plane |
| conGeom2 | Must be a line, linear edge, datum axis, or datum plane |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateConcentricConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates a concentric constraint. One of the input constraint geometries must be a curve.
| conGeom1 | Must be an arc or ellipse or edge shaped as an arc or ellipse |
| conGeom2 | Must be an arc or ellipse or edge shaped as an arc or ellipse |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateConstantAngleConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom | ) |
Creates a constant angle constraint
| conGeom | Must be a line |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateConstantLengthConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom | ) |
Creates a constant length constraint
| conGeom | Must be a line |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreateDiameterDimension | ( | const NXOpen::Sketch::DimensionGeometry & | dimObject1, |
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression ) |
Creates a diameter dimension constraint
| dimObject1 | Should be an arc |
| dimOrigin | The location where the dimension should be placed |
| expression | Defining expression for the dimension. Can be NULL |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreateDiameterDimension | ( | const NXOpen::Sketch::DimensionGeometry & | dimObject1, |
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression, | ||
| NXOpen::Sketch::DimensionOption | refDim ) |
Creates a diameter dimension constraint. Accepts a flag to create the dim as driving or reference
| dimObject1 | Should be an arc |
| dimOrigin | The location where the dimension should be placed |
| expression | Defining expression for the dimension. Can be NULL |
| refDim | option for creating driving or reference dimension |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreateDimension | ( | NXOpen::Sketch::ConstraintType | dimType, |
| const NXOpen::Sketch::DimensionGeometry & | dimObject1, | ||
| const NXOpen::Sketch::DimensionGeometry & | dimObject2, | ||
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression ) |
Creates a dimension between two geometric objects. Do not use for radial, diameter, or perimeter dimensions. To create a radial or diameter constraint, use NXOpen::Sketch::CreateRadialDimension or NXOpen::Sketch::CreateDiameterDimension . To create a perimeter dimension, use NXOpen::Sketch::CreatePerimeterDimension
| dimType | Must be one of the dimension types and should not be a radial, diametral, or perimeter dimension |
| dimObject1 | First input geometry |
| dimObject2 | Second input geometry |
| dimOrigin | The location where the dimension should be placed |
| expression | Defining expression for the dimension. Can be NULL |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreateDimension | ( | NXOpen::Sketch::ConstraintType | dimType, |
| const NXOpen::Sketch::DimensionGeometry & | dimObject1, | ||
| const NXOpen::Sketch::DimensionGeometry & | dimObject2, | ||
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression, | ||
| NXOpen::Sketch::DimensionOption | refDim ) |
Creates a dimension between two geometric objects. Do not use for radial, diameter, or perimeter dimensions. To create a radial or diameter constraint, use NXOpen::Sketch::CreateRadialDimension or NXOpen::Sketch::CreateDiameterDimension . To create a perimeter dimension, use NXOpen::Sketch::CreatePerimeterDimension . This function takes in an argument to create the dimension as driving or reference.
| dimType | Must be one of the dimension types and should not be a radial, diametral, or perimeter dimension |
| dimObject1 | First input geometry |
| dimObject2 | Second input geometry |
| dimOrigin | The location where the dimension should be placed |
| expression | Defining expression for the dimension. Can be NULL |
| refDim | option for creating driving or reference dimension |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateEqualLengthConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates an equal length constraint. One of the input constraint geometries must be a line.
| conGeom1 | Must be a line or linear edge |
| conGeom2 | Must be a line or linear edge |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateEqualRadiusConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates an equal radius constraint. One of the input constraint geometries must be a curve.
| conGeom1 | Must be an arc or edge shaped as an arc |
| conGeom2 | Must be an arc or edge shaped as an arc |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateFixedConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | geom | ) |
Creates a fixed constraint
| geom | Can be any curve, point, or vertex in the sketch |
| std::vector< NXOpen::SketchGeometricConstraint * > NXOpen::Sketch::CreateFullyFixedConstraints | ( | const NXOpen::Sketch::ConstraintGeometry & | geom | ) |
Creates enough fixed constraints on the curve and all of its vertices such that the geometry is fully fixed without any redundant fixed constraints.
| geom | Can be any curve, point, or vertex in the sketch |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateHorizontalConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | geom | ) |
Creates a horizontal constraint
| geom | Must be a line |
| NXOpen::Sketch::CreateInferConstraintSetting NXOpen::Sketch::CreateInferConstraintsSetting | ( | ) |
Returns the toggle that controls the creation of infer constraints in sketch
Created in NX4.0.0.
License requirements : None
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateMidpointConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates a midpoint constraint. One of the input constraint geometries must be a vertex and the other must be a curve or edge.
| conGeom1 | con geom1 |
| conGeom2 | con geom2 |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateNonUniformScaledConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom | ) |
Creates a non-uniform scale constraint
| conGeom | Must be a spline |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateNormalConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometryHelp & | geom1Help, | ||
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2, | ||
| const NXOpen::Sketch::ConstraintGeometryHelp & | geom2Help ) |
Creates a normal constraint. A normal constraint can be created between any two curve/edge type except between two linear objects. For linear objects, create a perpendicular constraint
| conGeom1 | First input geometry for the constraint |
| geom1Help | Help data for first geom |
| conGeom2 | Second input geometry for the constraint |
| geom2Help | Help data for second geom |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateParallelConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates a parallel constraint. A parallel constraint can only be created between one of the following pairs: (line, line or linear edge), (line, datum axis or datum plane), (line or linear edge, ellipse), (line, ellipse or elliptical edge), (ellipse, ellipse or elliptical edge).
| conGeom1 | First input geometry for the constraint |
| conGeom2 | Second input geometry for the constraint |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreatePerimeterDimension | ( | const std::vector< NXOpen::Curve * > & | curves, |
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression ) |
Creates a perimeter dimension constraint
| curves | The curves that form the perimeter |
| dimOrigin | Not currently used |
| expression | Defining expression for the dimension. Can be NULL |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreatePerpendicularConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates a perpendicular constraint. A perpendicular constraint can only be created between one of the following pairs: (line, line or linear edge), (line, datum axis or datum plane), (line or linear edge, ellipse), (line, ellipse or elliptical edge), (ellipse, ellipse or elliptical edge).
| conGeom1 | First input geometry for the constraint |
| conGeom2 | Second input geometry for the constraint |
| NXOpen::SketchHelpedGeometricConstraint * NXOpen::Sketch::CreatePointOnCurveConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2, | ||
| const NXOpen::Sketch::ConstraintGeometryHelp & | help ) |
Creates a point on curve constraint. One of the input geometries must be a vertex and the other must be a curve, edge, datum axis, or datum plane.
| conGeom1 | con geom1 |
| conGeom2 | con geom2 |
| help | help |
| NXOpen::SketchHelpedGeometricConstraint * NXOpen::Sketch::CreatePointOnStringConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const std::vector< NXOpen::Curve * > & | curvesInString, | ||
| const NXOpen::Sketch::ConstraintGeometryHelp & | helpData, | ||
| int | curveWhichHelpParamAppliesTo ) |
Creates a point on string constraint.
| conGeom1 | Must be a vertex |
| curvesInString | Must all be part of the same string. (You can create a string of curves through the UI through the Edit -> Project command.) |
| helpData | help data |
| curveWhichHelpParamAppliesTo | If helpData is a parameter, this parameter indicates which curve in the curvesInString that the help parameter applies to. Otherwise, this parameter is not used |
| NXOpen::SketchHelpedGeometricConstraint * NXOpen::Sketch::CreatePointOnStringConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| NXOpen::Curve * | curveInString, | ||
| const NXOpen::Sketch::ConstraintGeometryHelp & | helpData ) |
Creates a point on string constraint. The string is specified using a single curve in the string. The constraint is created on the entire string that curveInString belongs to.
| conGeom1 | Must be a vertex |
| curveInString | A curve in the string that you want to create the constraint on. The constraint is created on the entire string that this curve belongs to. (You can create a string of curves through the UI through the Edit -> Project command.) |
| helpData | help data |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreateRadialDimension | ( | const NXOpen::Sketch::DimensionGeometry & | dimObject1, |
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression ) |
Creates a radial dimension constraint
| dimObject1 | Should be an arc |
| dimOrigin | The location where the dimension should be placed |
| expression | Defining expression for the dimension. Can be NULL |
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::CreateRadialDimension | ( | const NXOpen::Sketch::DimensionGeometry & | dimObject1, |
| const NXOpen::Point3d & | dimOrigin, | ||
| NXOpen::Expression * | expression, | ||
| NXOpen::Sketch::DimensionOption | refDim ) |
Creates a radial dimension constraint. Accepts a flag to create the dimension as driving or reference
| dimObject1 | Should be an arc |
| dimOrigin | The location where the dimension should be placed |
| expression | Defining expression for the dimension. Can be NULL |
| refDim | option for creating driving or reference dimension |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateSlopeConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom1, |
| const NXOpen::Sketch::ConstraintGeometry & | conGeom2 ) |
Creates a slope constraint. One of the input constraint geometries must a spline defining point. The other must be datum axis, datum plane, or a curve or edge shaped as a line, arc, ellipse, conic, or spline.
| conGeom1 | con geom1 |
| conGeom2 | con geom2 |
| NXOpen::SketchTangentConstraint * NXOpen::Sketch::CreateTangentConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | geom1, |
| const NXOpen::Sketch::ConstraintGeometryHelp & | geom1Help, | ||
| const NXOpen::Sketch::ConstraintGeometry & | geom2, | ||
| const NXOpen::Sketch::ConstraintGeometryHelp & | geom2Help ) |
Creates a tangent constraint. Note: the input constraint geometries cannot both be linear.
| geom1 | A curve, edge, or datum axis |
| geom1Help | geom1 help |
| geom2 | A curve, edge, or datum axis |
| geom2Help | geom2 help |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateUniformScaledConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | conGeom | ) |
Creates a uniform scale constraint
| conGeom | Must be a spline |
| NXOpen::SketchGeometricConstraint * NXOpen::Sketch::CreateVerticalConstraint | ( | const NXOpen::Sketch::ConstraintGeometry & | geom | ) |
Creates a vertical constraint
| geom | Must be a line |
| void NXOpen::Sketch::Deactivate | ( | NXOpen::Sketch::ViewReorient | orientView, |
| NXOpen::Sketch::UpdateLevel | updateLevel ) |
Deactivates the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| orientView | Indicates whether to orient the view to the model during deactivation |
| updateLevel | Indicates whether just the sketch should be updated or the entire model |
| void NXOpen::Sketch::DeleteConstraintsOnGeometries | ( | const std::vector< NXOpen::NXObject * > & | objects | ) |
删除与对象及其所有顶点相关联的所有几何约束。将与对象及其顶点相关联的所有驱动尺寸转换为参考尺寸。
创建于 NX4.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| objects | 需删除约束的对象 |
| void NXOpen::Sketch::DeleteConstraintsOnGeometries | ( | const std::vector< NXOpen::Sketch::ConstraintGeometry > & | objects | ) |
删除与对象及其所有顶点相关联的所有几何约束。将与对象及其顶点相关联的所有驱动尺寸转换为参考尺寸。用户可以传入一个顶点,对提供的顶点执行相同操作。
创建于 NX8.5.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| objects | 需删除约束的对象 |
| void NXOpen::Sketch::DeleteConstraintsOnGeometries | ( | NXOpen::Sketch::ConstraintClass | conClass, |
| const std::vector< NXOpen::Sketch::ConstraintGeometry > & | objects ) |
根据约束类删除与输入草图几何和顶点相关联的约束,例如:
创建于 NX11.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| conClass | 如果不想按约束类筛选,请使用 NXOpen::Sketch::ConstraintClassAny |
| objects | 需删除约束的对象 |
| NXOpen::ErrorList * NXOpen::Sketch::DeleteObjects | ( | const std::vector< NXOpen::NXObject * > & | objects | ) |
从草图中删除对象
| objects | 要删除的对象 |
| bool NXOpen::Sketch::DOFDisplay | ( | ) |
Returns a flag indicating whether the degree of freedom arrows are currently being displayed
Created in NX3.0.0.
License requirements : None
| void NXOpen::Sketch::EditSplineDefiningPoints | ( | NXOpen::Spline * | spline, |
| const std::vector< double > & | points ) |
更改样条曲线的定义点位置。points 数组长度需足够覆盖现有定义点。无法通过此调用添加/删除点或更改节点序列。
创建于 NX10.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| spline | 样条曲线 |
| points | 定义点位置。大小为点数的三倍。 |
| void NXOpen::Sketch::EditSplinePoles | ( | NXOpen::Spline * | spline, |
| const std::vector< double > & | poles ) |
更改样条曲线的控制点位置。poles 数组长度需足够覆盖现有控制点。无法通过此调用添加/删除控制点或更改节点序列。poles 数组中的数据顺序为 x、y、z、权重。可通过此函数编辑任意或所有这四个值。
创建于 NX10.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| spline | 样条曲线 |
| poles | 控制点位置。大小为点数的四倍。 |
| NXOpen::Features::Feature * NXOpen::Sketch::Feature | ( | ) |
返回与此草图关联的特征
创建于 NX3.0.0。
许可要求:无
| std::vector< NXOpen::Arc * > NXOpen::Sketch::Fillet | ( | NXOpen::Curve * | curve1, |
| NXOpen::Curve * | curve2, | ||
| const NXOpen::Point3d & | helpPoint1, | ||
| const NXOpen::Point3d & | helpPoint2, | ||
| const NXOpen::Point3d & | pointOnArc, | ||
| double | radius, | ||
| NXOpen::Sketch::TrimInputOption | doTrim, | ||
| NXOpen::Sketch::CreateDimensionOption | createRadiusDim, | ||
| NXOpen::Sketch::AlternateSolutionOption | alternateSolution, | ||
| std::vector< NXOpen::SketchConstraint * > & | constraints ) |
Fillets curves and creates appropriate constraints. If the input curves have mirror constraints, the fillet is also performed on the mirror curves.
| curve1 | First curve for the fillet |
| curve2 | Second curve for the fillet |
| helpPoint1 | Should be a point on the first curve. Indicates where the fillet should be created |
| helpPoint2 | Should be a point on the second curve. Indicates where the fillet should be created |
| pointOnArc | Point on fillet arc |
| radius | Radius of the fillet |
| doTrim | Indicates whether the input curves should get trimmed by the fillet |
| createRadiusDim | Indicates whether a radius dimension should be created |
| alternateSolution | Indicates whether the alternate solution should be used instead of the regular solution. The alternate solution for an arc is the portion of the full circle that is left out of the regular solution. |
| constraints | The constraints that were created by the fillet. If the input curves get trimmed, coincident and tangent constraints are created. If the input curves do not get trimmed, point on curve and tangent constraints are created. |
| std::vector< NXOpen::Arc * > NXOpen::Sketch::Fillet | ( | NXOpen::Curve * | curve1, |
| NXOpen::Curve * | curve2, | ||
| const NXOpen::Point3d & | helpPoint1, | ||
| const NXOpen::Point3d & | helpPoint2, | ||
| double | radius, | ||
| NXOpen::Sketch::TrimInputOption | doTrim, | ||
| NXOpen::Sketch::CreateDimensionOption | createRadiusDim, | ||
| NXOpen::Sketch::AlternateSolutionOption | alternateSolution, | ||
| std::vector< NXOpen::SketchConstraint * > & | constraints ) |
Fillets curves and creates appropriate constraints. If the input curves have mirror constraints, the fillet is also performed on the mirror curves.
| curve1 | First curve for the fillet |
| curve2 | Second curve for the fillet |
| helpPoint1 | Should be a point on the first curve. Indicates where the fillet should be created |
| helpPoint2 | Should be a point on the second curve. Indicates where the fillet should be created |
| radius | Radius of the fillet |
| doTrim | Indicates whether the input curves should get trimmed by the fillet |
| createRadiusDim | Indicates whether a radius dimension should be created |
| alternateSolution | Indicates whether the alternate solution should be used instead of the regular solution. The alternate solution for an arc is the portion of the full circle that is left out of the regular solution. |
| constraints | The constraints that were created by the fillet. If the input curves get trimmed, coincident and tangent constraints are created. If the input curves do not get trimmed, point on curve and tangent constraints are created. |
| std::vector< NXOpen::Arc * > NXOpen::Sketch::Fillet | ( | NXOpen::Curve * | curve1, |
| NXOpen::Curve * | curve2, | ||
| NXOpen::Curve * | curve3, | ||
| const NXOpen::Point3d & | helpPoint1, | ||
| const NXOpen::Point3d & | helpPoint2, | ||
| const NXOpen::Point3d & | helpPoint3, | ||
| const NXOpen::Point3d & | pointOnArc, | ||
| double | radius, | ||
| NXOpen::Sketch::TrimInputOption | doTrim, | ||
| NXOpen::Sketch::DeleteThirdCurveOption | doDelete, | ||
| NXOpen::Sketch::CreateDimensionOption | createRadiusDim, | ||
| NXOpen::Sketch::AlternateSolutionOption | alternateSolution, | ||
| std::vector< NXOpen::SketchConstraint * > & | constraints ) |
Fillets curves and creates appropriate constraints. If the input curves have mirror constraints, the fillet is also performed on the mirror curves.
| curve1 | First curve for the fillet |
| curve2 | Second curve for the fillet |
| curve3 | Third curve for the fillet |
| helpPoint1 | Should be a point on the first curve. Indicates where the fillet should be created |
| helpPoint2 | Should be a point on the second curve. Indicates where the fillet should be created |
| helpPoint3 | Should be a point on the third curve. Indicates where the fillet should be created |
| pointOnArc | Point on fillet arc |
| radius | Radius of the fillet |
| doTrim | Indicates whether the input curves should get trimmed by the fillet |
| doDelete | Indicates whether the third curve should be deleted |
| createRadiusDim | Indicates whether a radius dimension should be created |
| alternateSolution | Indicates whether the alternate solution should be used instead of the regular solution. The alternate solution for an arc is the portion of the full circle that is left out of the regular solution. |
| constraints | The constraints that were created by the fillet. If the input curves get trimmed, coincident and tangent constraints are created. If the input curves do not get trimmed, point on curve and tangent constraints are created. |
| std::vector< NXOpen::Arc * > NXOpen::Sketch::Fillet | ( | NXOpen::Curve * | curve1, |
| NXOpen::Curve * | curve2, | ||
| NXOpen::Curve * | curve3, | ||
| const NXOpen::Point3d & | helpPoint1, | ||
| const NXOpen::Point3d & | helpPoint2, | ||
| const NXOpen::Point3d & | helpPoint3, | ||
| double | radius, | ||
| NXOpen::Sketch::TrimInputOption | doTrim, | ||
| NXOpen::Sketch::DeleteThirdCurveOption | doDelete, | ||
| NXOpen::Sketch::CreateDimensionOption | createRadiusDim, | ||
| NXOpen::Sketch::AlternateSolutionOption | alternateSolution, | ||
| std::vector< NXOpen::SketchConstraint * > & | constraints ) |
Fillets curves and creates appropriate constraints. If the input curves have mirror constraints, the fillet is also performed on the mirror curves.
| curve1 | First curve for the fillet |
| curve2 | Second curve for the fillet |
| curve3 | Third curve for the fillet |
| helpPoint1 | Should be a point on the first curve. Indicates where the fillet should be created |
| helpPoint2 | Should be a point on the second curve. Indicates where the fillet should be created |
| helpPoint3 | Should be a point on the third curve. Indicates where the fillet should be created |
| radius | Radius of the fillet |
| doTrim | Indicates whether the input curves should get trimmed by the fillet |
| doDelete | Indicates whether the third curve should be deleted |
| createRadiusDim | Indicates whether a radius dimension should be created |
| alternateSolution | Indicates whether the alternate solution should be used instead of the regular solution. The alternate solution for an arc is the portion of the full circle that is left out of the regular solution. |
| constraints | The constraints that were created by the fillet. If the input curves get trimmed, coincident and tangent constraints are created. If the input curves do not get trimmed, point on curve and tangent constraints are created. |
| void NXOpen::Sketch::FlipNormal | ( | ) |
Flips the outward normal vector of the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::FlipReferenceDirection | ( | ) |
Flips the reference direction of the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| std::vector< NXOpen::SketchConstraint * > NXOpen::Sketch::GetAllConstraintsOfType | ( | NXOpen::Sketch::ConstraintClass | conClass, |
| NXOpen::Sketch::ConstraintType | conType ) |
Gets all constraints in the sketch of a particular type
| conClass | Optional filter. Use NXOpen::Sketch::ConstraintClassAny if you do not want to filter by constraint class |
| conType | Optional filter. Use NXOpen::Sketch::ConstraintTypeNoCon if you do not want to filter by constraint type |
| std::vector< NXOpen::Expression * > NXOpen::Sketch::GetAllExpressions | ( | ) |
Returns all the expressions in the sketch
| std::vector< NXOpen::NXObject * > NXOpen::Sketch::GetAllGeometry | ( | ) |
Returns all the curves and points in the sketch
| NXOpen::SketchDimensionalConstraint * NXOpen::Sketch::GetConstraintFromDimension | ( | NXOpen::Annotations::Dimension * | dimension | ) |
Get the constraint associated with the input sketch dimension. The dimension must be owned by this sketch, which means that NXOpen::Sketch::IsSketchDimension returns true. To get the dimension from a constraint, use NXOpen::SketchDimensionalConstraint::AssociatedDimension
| dimension | Sketch dimension |
| std::vector< NXOpen::SketchConstraint * > NXOpen::Sketch::GetConstraintsForGeometry | ( | NXOpen::SmartObject * | geometry, |
| NXOpen::Sketch::ConstraintClass | conClass ) |
Gets all the constraints associated with a particular geometric item
| geometry | Must be a curve or point |
| conClass | Optional filter. Use NXOpen::Sketch::ConstraintClassAny if you do not want to filter by constraint class |
| std::vector< NXOpen::SketchRelation * > NXOpen::Sketch::GetIgnoredRelationsOfGeometry | ( | const NXOpen::Sketch::ConstraintGeometry & | geometry | ) |
方法返回几何上的忽略关系
| geometry | 几何 |
| NXOpen::NXObject * NXOpen::Sketch::GetParentOfIncludedGeometry | ( | NXOpen::SmartObject * | geometry | ) |
返回包含几何的父对象。
| geometry | 必须是包含几何 |
| NXOpen::Vector3d NXOpen::Sketch::GetReferenceDirection | ( | NXOpen::IReferenceAxis ** | referenceAxis, |
| NXOpen::AxisOrientation * | referenceAxisOrientation, | ||
| NXOpen::Sense * | referenceAxisSense ) |
Gets the reference direction of the sketch
| referenceAxis | An edge, datum axis, datum plane, or face that the sketch uses as a reference. May be NULL. |
| referenceAxisOrientation | Indicates whether the reference axis is horizontal or vertical |
| referenceAxisSense | If reference axis is an edge or datum axis, this parameter indicates whether the reference axis is in the same direction as the edge or datum axis or in the opposite direction. If reference axis is not an edge or datum axis, this parameter is not used. |
| std::vector< NXOpen::SmartObject * > NXOpen::Sketch::GetRemoteFindingCurves | ( | ) |
返回草图中所有启用远程查找的曲线。
| NXOpen::Sketch::Status NXOpen::Sketch::GetStatus | ( | int * | dofNeeded | ) |
Gets the status of the sketch and the number of degrees of freedom that remain in the sketch. The status of the sketch indicates whether the sketch is fully constrained or under, over, or inconsistently constrained.
| dofNeeded | The number of degrees of freedom left in the sketch |
| std::vector< NXOpen::SketchVirtualPoint * > NXOpen::Sketch::GetVirtualPoints | ( | ) |
返回草图中的所有虚拟点
| void NXOpen::Sketch::HideDimensions | ( | ) |
隐藏输入草图的所有尺寸
创建于 NX6.0.1。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::HideDimensions | ( | const std::vector< NXOpen::DisplayableObject * > & | inputObjects | ) |
隐藏活动草图中与输入草图几何相关联的尺寸。
创建于 NX4.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| inputObjects | 活动草图中的几何和组 |
| void NXOpen::Sketch::HideDimensions | ( | const std::vector< NXOpen::Sketch::ConstraintGeometry > & | objects | ) |
隐藏活动草图中与输入草图几何相关联的尺寸。此函数可接受顶点
创建于 NX8.5.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| objects | 活动草图中的几何和顶点 |
| NXOpen::InfiniteLine * NXOpen::Sketch::HorizontalAxis | ( | ) |
Returns the infinite horizontal axis of the sketch, if one exists. This axis is internal to the sketch and should not be edited or deleted.
Created in NX2306.3000.0.
License requirements : None
| bool NXOpen::Sketch::IsActive | ( | ) |
Returns true if the sketch is active
Created in NX3.0.0.
License requirements : None
| bool NXOpen::Sketch::IsDraftingSketch | ( | ) |
如果是工程图草图则返回 true
创建于 NX6.0.0。
许可要求:无
| bool NXOpen::Sketch::IsIncludedGeometry | ( | NXOpen::SmartObject * | geometry | ) |
判断输入几何是否为包含的曲线或点,是则返回true。
| geometry | 必须是曲线或点 |
| bool NXOpen::Sketch::IsInternal | ( | ) |
返回草图是否为内部。
创建于 NX6.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 geometric_tol ("GDT")
| bool NXOpen::Sketch::IsSketchConstraint | ( | NXOpen::SketchConstraint * | constraint | ) |
Determine if the input constraint is owned by the sketch. Returns true for the constraints returned by NXOpen::Sketch::GetAllConstraintsOfType .
| constraint | Candidate constraint |
| bool NXOpen::Sketch::IsSketchDimension | ( | NXOpen::Annotations::Dimension * | dimension | ) |
Determine if the input dimension is owned by the sketch. Returns true for a dimension whose associated constraint is returned by NXOpen::Sketch::GetAllConstraintsOfType .
| dimension | Candidate dimension |
| bool NXOpen::Sketch::IsSketchGeometry | ( | NXOpen::SmartObject * | geometry | ) |
Determine if the input curve or point is owned by the sketch. Returns true for the sketch origin, sketch axes, and the sketch geometry returned by NXOpen::Sketch::GetAllGeometry .
| geometry | Must be a curve or point |
| void NXOpen::Sketch::LocalUpdate | ( | ) |
Update the sketch and not the sketch children. If a different sketch is active the SKETCH_NOT_INITIALIZED error will return. The function works even if the sketch is not active.
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::MakeDatumsExternal2 | ( | ) |
将内部草图放置面和方向参考基准设为外部。仅当内部基准不是基准 CSYS 或不是 PlaneAxisPoint 类型的基准 CSYS 时才调用此函数。
创建于 NX11.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 geometric_tol ("GDT")
| std::vector< NXOpen::SketchConstraint * > NXOpen::Sketch::MakeRelationPersistent | ( | const std::vector< NXOpen::NXObject * > & | foundRelations | ) |
将所有输入的 NXOpen::SketchFoundRelation 类型对象转换为 NXOpen::SketchConstraint 。 此过程中会终止任何活动操作。不支持圆角、槽和偏置关系。同时按任意顺序获取新的持久关系。
创建于 NX2406.0.0。
许可要求:实体建模("SOLIDS MODELING")或工程图("DRAFTING")或几何公差("GDT")
| foundRelations | 待转换的关系对象 |
| void NXOpen::Sketch::ManageConstraintsAfterEdit | ( | const std::vector< NXOpen::NXObject * > & | sketchGeoms, |
| bool | preserveComplexConstraints ) |
删除或调整几何编辑后不兼容的输入几何约束。在草图更新前调用
创建于 NX11.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| sketchGeoms | sketchgeoms |
| preserveComplexConstraints | 复杂约束包括Pattern、Mirror和Offset |
| bool NXOpen::Sketch::MechanismMode | ( | ) |
返回草图是否处于机构模式的标志
创建于 NX2206.0.0。
许可要求:无
| NXOpen::Sketch::NX_DEPRECATED | ( | "Deprecated in NX11.0.0. None." | ) |
如果草图放置面和方向参考基准仅被草图引用,则将其设为草图内部。
| NXOpen::Sketch::NX_DEPRECATED | ( | "Deprecated in NX11.0.0. Please use NXOpen::Sketch::MakeDatumsExternal2 instead." | ) |
将内部草图放置面和方向参考基准设为外部。
| NXOpen::NXMatrix * NXOpen::Sketch::Orientation | ( | ) |
Returns the orientation matrix of the local coordinate system of the sketch
Created in NX3.0.0.
License requirements : None
| NXOpen::Point3d NXOpen::Sketch::Origin | ( | ) |
Returns the location of the origin of the local coordinate system for the sketch
Created in NX3.0.0.
License requirements : None
| NXOpen::Point * NXOpen::Sketch::OriginPoint | ( | ) |
Returns the origin point of the sketch, if one exists. This point is internal to the sketch and should not be edited or deleted.
Created in NX2306.3000.0.
License requirements : None
| NXOpen::Preferences::SketchPreferences * NXOpen::Sketch::Preferences | ( | ) |
包含草图的首选项设置
创建于 NX3.0.0。
| void NXOpen::Sketch::RemoveRedundantVertices | ( | const std::vector< NXOpen::NXObject * > & | geoms | ) |
移除给定草图几何的冗余顶点
创建于 NX11.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| geoms | 几何数组 |
| void NXOpen::Sketch::RenewDraftingSketch | ( | ) |
更新工程图草图至最新求解器版本。更新草图特征需使用 NXOpen::GeometricUtilities::RenewFeatureBuilder 。
创建于 NX2306.0.0。
许可要求:工程图("DRAFTING")
| bool NXOpen::Sketch::RotateDragMode | ( | ) |
返回控制活动草图中旋转拖动模式的开关。
创建于 NX1899.0.0。
许可要求:无
| void NXOpen::Sketch::RunAutoDimension | ( | ) |
Run auto dimensioning.
Created in NX7.5.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::Scale | ( | double | scaleFactor | ) |
按给定比例因子缩放草图实体。如果存在配方曲线、外部约束/尺寸或控制草图中一个或多个几何尺寸的约束/尺寸,则无法缩放草图。草图最多可包含一个非角度驱动尺寸,且该尺寸的表达式值必须按比例因子缩放。
创建于 NX11.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| scaleFactor | 比例因子必须大于零 |
| void NXOpen::Sketch::SetCreateInferConstraintsSetting | ( | NXOpen::Sketch::CreateInferConstraintSetting | createInferCon | ) |
Sets the toggle that controls the creation of infer constraints in sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| createInferCon | create infer con |
| void NXOpen::Sketch::SetDOFDisplay | ( | bool | displayDof | ) |
Sets a flag indicating whether the degree of freedom arrows are currently being displayed
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| displayDof | display dof |
| void NXOpen::Sketch::SetMechanismMode | ( | bool | isMechanismMode | ) |
设置草图是否处于机构模式,true为是,false为否
创建于 NX2206.0.0。
许可要求:实体建模("SOLIDS MODELING")
| isMechanismMode | 机构模式状态:true表示草图处于机构模式。 |
| void NXOpen::Sketch::SetReferenceDirection | ( | NXOpen::IReferenceAxis * | referenceAxis, |
| const NXOpen::Vector3d & | referenceDirection, | ||
| NXOpen::AxisOrientation | referenceAxisOrientation, | ||
| NXOpen::Sense | referenceAxisSense ) |
Sets the reference direction of the sketch.
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| referenceAxis | Can be a datum axis, edge, datum plane, face, or NULL. If it is an edge, the edge must be a line segment. If it is a face, the face must be a plane. If NULL, the reference_direction is used instead. |
| referenceDirection | If reference_axis is NULL, this parameter sets the reference direction of the sketch. In this case, this parameter must not be (0,0,0). If reference_axis is not NULL and this parameter is not (0,0,0), this parameter determines whether the reference direction should be in the same direction as reference_axis or in the opposite direction. If this parameter is (0,0,0), this parameter is not used. |
| referenceAxisOrientation | Indicates whether the reference axis is horizontal or vertical. |
| referenceAxisSense | Ignored unless reference_direction is (0,0,0) and reference_axis is an edge or datum axis. This parameter indicates whether the reference axis should be in the same direction as reference_axis or in the opposite direction. |
| void NXOpen::Sketch::SetRotateDragMode | ( | bool | rotateDrag | ) |
设置控制活动草图中旋转拖动模式的开关。
创建于 NX1899.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| rotateDrag | rotatedrag |
| void NXOpen::Sketch::SetRotationOrigin | ( | const NXOpen::Point3d & | center | ) |
设置旋转原点
创建于 NX1899.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| center | center |
| void NXOpen::Sketch::SetTextHeight | ( | double | textHeight | ) |
设置给定草图中所有尺寸的文字高度。 如果零件类型为公制,则文字高度单位为毫米。 如果零件类型为英制,则文字高度单位为英寸。 注意:只有当 NXOpen::Preferences::SketchPreferences::SetTextSizeMode 设置为可变模式时,才能更改高度。
创建于 NX1899.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| textHeight | 文字高度必须大于零 |
| void NXOpen::Sketch::SetUpdateScope | ( | NXOpen::Sketch::UpdateLevel | updateScope | ) |
设置当前更新范围。用于直接草图中控制更新
创建于 NX8.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| updateScope | 更新范围 |
| void NXOpen::Sketch::SetUpgradeUponActivation | ( | bool | upgrade | ) |
设置导致草图在激活时升级的标志
创建于 NX1926.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") 或 drafting ("DRAFTING") 或 geometric_tol ("GDT")
| upgrade | 当为true时,草图激活时将升级。 |
| void NXOpen::Sketch::ShowDimensions | ( | ) |
取消隐藏输入草图的所有尺寸
创建于 NX6.0.1。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::ShowDimensions | ( | const std::vector< NXOpen::DisplayableObject * > & | inputObjects | ) |
取消隐藏活动草图中与输入草图几何相关联的尺寸
创建于 NX4.0.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| inputObjects | 活动草图中的几何和组 |
| void NXOpen::Sketch::ShowDimensions | ( | const std::vector< NXOpen::Sketch::ConstraintGeometry > & | objects | ) |
取消隐藏活动草图中与输入草图几何相关联的尺寸。此函数可以接受顶点。
创建于 NX8.5.0。
许可要求:solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| objects | 活动草图中的几何和顶点 |
| void NXOpen::Sketch::Update | ( | ) |
Updates the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| void NXOpen::Sketch::Update | ( | const std::vector< NXOpen::NXObject * > & | geoms | ) |
Updates the given set of geometries in the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT") OR nx_freeform_1 ("basic freeform modeling")
| geoms | Geoms that need to be updated |
| void NXOpen::Sketch::UpdateConstraintDisplay | ( | ) |
Updates the constraint display without updating the sketch
Created in NX3.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::UpdateConstraintDisplay | ( | const std::vector< NXOpen::SmartObject * > & | geoms | ) |
Updates the constraint display of given set of geoms without updating the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| geoms | Geoms for which cons must be re-displayed |
| void NXOpen::Sketch::UpdateDimensionDisplay | ( | ) |
Updates the dimension display without updating the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::UpdateDimensionDisplay | ( | const std::vector< NXOpen::NXObject * > & | dims | ) |
Updates the dimension display of given set of dims without updating the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING")
| dims | Dims for which cons must be re-displayed |
| void NXOpen::Sketch::UpdateDimensionDisplay | ( | const std::vector< NXOpen::SmartObject * > & | geoms | ) |
Updates the dimension display of given set of geoms without updating the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| geoms | Geoms for which cons must be re-displayed |
| void NXOpen::Sketch::UpdateGeometryDisplay | ( | ) |
Updates the geometry display without updating the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| void NXOpen::Sketch::UpdateGeometryDisplay | ( | const std::vector< NXOpen::SmartObject * > & | geoms | ) |
Updates the geometry display of given set of geoms without updating the sketch
Created in NX4.0.0.
License requirements : solid_modeling ("SOLIDS MODELING") OR drafting ("DRAFTING") OR geometric_tol ("GDT")
| geoms | Geoms for which cons must be re-displayed |
| void NXOpen::Sketch::UpdateNavigator | ( | ) |
更新草图导航器。若输入草图不是活动草图,将返回 SKETCH_NOT_INITIALIZED 错误。
创建于 NX2406.0.0。
许可要求:实体建模("SOLIDS MODELING")或工程图("DRAFTING")或几何公差("GDT")
| NXOpen::Sketch::UpdateLevel NXOpen::Sketch::UpdateScope | ( | ) |
返回当前更新范围。用于直接草图中控制更新
创建于 NX8.0.0。
许可要求:无
| bool NXOpen::Sketch::UpgradeUponActivation | ( | ) |
返回导致草图在激活时升级的标志
创建于 NX1926.0.0。
许可要求:无
| bool NXOpen::Sketch::UsesLegacySolver | ( | ) |
返回草图是否使用旧版求解器或无求解器的标志。
创建于 NX1980.0.0。
许可要求:无
| NXOpen::InfiniteLine * NXOpen::Sketch::VerticalAxis | ( | ) |
Returns the infinite vertical axis of the sketch, if one exists. This axis is internal to the sketch and should not be edited or deleted.
Created in NX2306.3000.0.
License requirements : None
| NXOpen::View * NXOpen::Sketch::View | ( | ) |
返回与草图对应的视图
创建于 NX6.0.0。
许可要求:无