Element Trees: Cosmetic Thread
This section describes how to construct and access the element tree for Cosmetic Thread features. It also shows how to create, redefine, and access the properties of these features.
Introduction
A cosmetic thread is a cosmetic feature that represents the diameter of a thread. It is displayed in purple. Unlike other cosmetic features, you cannot modify the line style of a cosmetic thread.
You can create cosmetic threads using cylinders, cones, splines, and non-normal planes as the references. The surface that you select determines whether a cosmetic thread is external or internal. If the surface is a shaft, the thread is external. If the surface is a hole, the thread is internal.
You can create a standard thread or a nonstandard thread. When you choose to create a standard thread, the standard thread series and diameter is used. You can create, edit, and redefine the cosmetic thread features.
The Element Tree for Cosmetic Thread
The element tree for the cosmetic thread feature is documented in the header file ProThread.h, and is shown in the following figure.
Element Tree for Cosmetic Thread
Image
The following table describes the elements in the element tree for the cosmetic thread feature:
Element ID
Data Type
Description
PRO_E_FEATURE_TYPE
PRO_VALUE_TYPE_INT
Specifies the type of feature
PRO_E_FEATURE_FORM
PRO_VALUE_TYPE_INT
Optional element. Specifies the type of the feature form. Use the value PRO_EXTRUDE or PRO_REVOLVE from the enumerated type ProFeatFormType depending on the threaded surface.
•  Use PRO_EXTRUDE when the referenced threaded surface is cylindrical.
•  Use PRO_REVOLVE when the referenced threaded surface is conical.
Note
If the enumerated value and referenced threaded surface are incorrectly selected, the feature creation or redefinition will fail.
PRO_E_STD_FEATURE_NAME
PRO_VALUE_TYPE_WSTRING
Optional element. Specifics the cosmetic thread feature name. The default value is COSMETIC_THREAD.
PRO_E_THRD_TYPE_OPT_NEW
PRO_VALUE_TYPE_BOOLEAN
Optional element. Specifies if a simple or a standard thread should be created. It has two values: FALSE for simple thread and TRUE for standard thread.
PRO_E_THRD_SERIES_NEW
PRO_VALUE_TYPE_INT
Specific the thread series for the standard threads. From the *.hol files information about different THREAD_SERIES is gathered and a list is generated. You can specify UNC, UNF, and ISO as the standard thread series. The current index to the list is stored in this element.
PRO_E_THRD_SCREWSIZE_NEW
PRO_VALUE_TYPE_INT
Optional element. Specifies the screw size for the standard thread. The screw_size list is extracted from the *.hol files corresponding to the thread series. The index to the screw_size list is stored in this element.
PRO_E_THRD_SURF_NEW
PRO_VALUE_TYPE_SELECTION
Specifies the surface to thread.
PRO_E_THRD_DIAM_NEW
PRO_VALUE_TYPE_DOUBLE
Optional element. Specifies the diameter for a simple thread. If the reference threaded surface is conical, the thread diameter value can be between 0.0 and diam/4, where diam is the largest estimated diameter of the cone. For all other reference surfaces, the diameter can have values between 0.1 and MAX_DIM_VALUE, that is the maximum allowed diameter value.
PRO_E_THRD_START_REF_NEW
PRO_VALUE_TYPE_SELECTION
Specifies the starting location of the cosmetic thread.
PRO_E_THRD_DEP_COMP_NEW
Compound
Specifies the depth and flip elements. It contains the following elements:
•  PRO_E_THRD_DEP_OPT
_NEW
•  PRO_E_THRD_FLIP_OPT
_NEW
•  PRO_E_THRD_DEP_VAL
_NEW
•  PRO_E_THRD_END_REF
PRO_E_THRD_DEP_OPT_NEW
PRO_VALUE_TYPE_BOOLEAN
Optional element. Specifies the depth option: FALSE for blind depth option and TRUE for the depth up to the selected entity.
PRO_E_THRD_FLIP_OPT_NEW
PRO_VALUE_TYPE_INT
Optional element. Specifies the flip direction of the thread with respect to the reference surface. The flip direction is specified by the enumerated type ProThreadFlip that takes the following values:
•  PRO_COSTHREAD_THD
_FLIP_OPT_FLIP
•  PRO_COSTHREAD_THD
_FLIP_OPT_NORM
PRO_E_THRD_DEP_VAL_NEW
PRO_VALUE_TYPE_DOUBLE
Optional element. Specifies the depth value when the element PRO_E_THRD_DEP_OPT_NEW is FALSE (Blind option). You can specify a minimum depth of 0.1. When the element PRO_E_THRD_DEP_OPT_NEW is TRUE, the node is invisible.
PRO_E_THRD_END_REF
PRO_VALUE_TYPE_SELECTION
Mandatory element when PRO_E_THRD_DEP_OPT_NEW is TRUE. Specifies the reference surface up to which the thread depth should be created. This node is available only when the element PRO_E_THRD_DEP_OPT_NEW is TRUE. When the element PRO_E_THRD_DEP_OPT_NEW is FALSE, the node is invisible.
PRO_E_THRD_NOTE_
PARAMS_NEW
PRO_VALUE_TYPE_POINTER
Reserved for future use. Optional element. Displays the thread parameters in a data structure.