Distance Dimension
Distance dimension is set for a pair of geometric objects. Table 1 shows geometry type pairs supported for distance dimensions by the C3D Solver. Table 1 - Geometric object pairs supported for distance dimensions
Point |
Line |
Circle |
Ellipse |
Spline |
Parametric curve |
|
|---|---|---|---|---|---|---|
Point |
\(\surd\) |
\(\surd\) |
\(\surd\) |
|||
Line |
\(\surd\) |
\(\surd\) |
\(\surd\) |
|||
Circle |
\(\surd\) |
\(\surd\) |
\(\surd\) |
|||
Ellipse |
||||||
Spline |
||||||
Parametric curve |
Regardless of curve type associated with the distance dimension, it measures the distance between points lying on the curves. These are usually the points that provide the smallest distance between the objects. However, it is also possible to choose other point pairs to measure the dimension. Fig. 28.1.2. in Item Auxiliary Points of Distance Dimension shows four examples of various distance dimensions for the same pair of circles.
Distance dimension for a couple of geometric objects is set [by the]{#GCE_AddDistance}
constraint_item GCE_AddDistance(GCE_system gSys, geom_item g[2]
, const GCE_ldim_pars & dPars);
The function returns a distance dimension descriptor set for the objects g[0] and g[1] belonging to the gSys constraint system.
The dPars parameter structure defines the following distance dimension settings:
dPars.dPars sets the parameter value, it can be either and independent parameter or a variable;
dPars.hp[2] is a pair of auxiliary points that set the measurement result when it is required (learn more in Item Auxiliary Points of Distance Dimension).
The dPars.dPars parameter actually defines the source, where the dimension value is taken. If dPars.dPars.var = GCE_NULL_V, then the dimension value is determined by the independent numeric parameter dPars.dPars.dimValue, which makes this dimension a driving dimension. If dPars.dPars.var contains variable descriptor, then the dimension is variational. Driving and variational dimensions were discussed in more detail in Item Driving and Variational Dimensions.
A pair of auxiliary point descriptors dPars.hp[2] is not mandatory, if the dimension measurement variant is unique (for example, the distance between a point and a line) or if it can be selected by the solver that would choose the measurement variant closest to the current object position and the dimension value. In this case, dPars.hp[2] is by default equal to a pair of zero descriptors {GCE_NULL, GCE_NULL}. If one or both auxiliary points dPars.hp[0] and dPars.hp[1] are defined, then the coordinates of these points would specify the measurement option for the distance dimension. Measurement options are described in more detail in Item Auxiliary Points of Distance Dimension.