 |
PK_CURVE_project_o_t |
|
struct PK_CURVE_project_o_s
{
int o_t_version; --- version number of options
PK_proj_method_t method; --- the method of projection
--- (PK_proj_method_unset_c)
PK_LOGICAL_t have_direction; --- whether 'direction' is set
--- (PK_LOGICAL_false)
PK_VECTOR1_t direction; --- the direction of projection
--- (0.0 0.0 0.0)
PK_VECTOR_t eye_position; --- position for perspective
--- projection
--- (0.0 0.0 0.0)
PK_LOGICAL_t bidirectional; --- bidirectional projection
--- (PK_LOGICAL_false)
PK_proj_max_dist_t use_max_dist; --- how to limit projection
--- (PK_proj_max_dist_no_c)
double max_dist; --- limiting projection distance
--- (0.0)
PK_proj_face_hidden_t hidden; --- how to project to hidden faces
--- (PK_proj_face_hidden_body_c)
PK_proj_connect_t connect; --- how to connect disjoint outputs
--- (PK_proj_connect_none_c)
PK_CLASS_array_t banned_classes; --- array of curve classes which are
--- forbidden (0, NULL)
PK_proj_split_clash_t split_clash; --- how to split resulting clashes
--- (PK_proj_split_clash_all_c)
PK_proj_to_points_t create_points; --- how to project curves to points
--- (PK_proj_to_points_no_c)
PK_LOGICAL_t construction; --- whether to add as construction
--- geometry (PK_LOGICAL_true)
double tolerance; --- operation tolerance
--- (1.0e-6)
PK_proj_function_t function; --- whether to project or imprint
--- (PK_proj_function_project_c)
PK_imprint_precision_t
imprint_precision;
--- how to set precision of imprints
--- (PK_imprint_precision_auto_c)
PK_proj_nominal_t nominal; --- whether to attach as nominal
--- geometry (PK_proj_nominal_no_c)
PK_proj_complete_t complete; --- how to complete imprints
--- (PK_proj_complete_no_c)
PK_complete_bound_t complete_bound; --- how to bound imprint completion
--- (PK_complete_bound_none_c)
double complete_bound_distance;
--- distance bound for imprint
--- completion (0.0)
PK_proj_update_t update; --- update switch
--- (PK_proj_update_default_c)
PK_proj_tracking_t tracking; --- format of track records
--- (PK_proj_tracking_basic_c)
PK_results_output_t results_output; --- whether to output results in the
--- return structure or in a report
--- (PK_results_output_return_c)
PK_LOGICAL_t want_orig_intervals;
--- whether to return the
--- originating intervals for
--- each projection
--- (PK_LOGICAL_false)
};
typedef struct PK_CURVE_project_o_s PK_CURVE_project_o_t;
This options structure holds optional controls for PK_CURVE_project.
Specific Errors:
PK_ERROR_bad_tolerance (MILD) The supplied 'tolerance' option
is zero or negative, or the
supplied 'tolerance' option is
invalid for the supplied
'max_dist' or
'complete_bound_distance'
options.
PK_ERROR_distance_le_0 (MILD) The 'use_max_dist' option has a
non-default value and
'max_dist' is less than or
equal to zero, or the
'complete_bound' option has a
non-default value and
'complete_bound_distance' is
less than or equal to zero.
PK_ERROR_bad_position (MILD) The 'eye_position' is placed
outside the size box or is
closer than 'tolerance'
to one of the input curves.
PK_ERROR_bad_class (MILD) The 'banned_classes' array
contains an unsupported class or
combination of classes.
Used in:
PK_CURVE_project
Description of fields:
'method' Whether to perform a normal, vector or perspective
projection.
'have_direction' Whether a projection direction is supplied using the
'direction' to define a vector projection. The default
is PK_LOGICAL_false.
Note: This option has been superseded by the 'method'
option.
'direction' If 'method' is PK_proj_method_vector_c this option
specifies the direction of vector projection.
'eye_position' If 'method' is PK_proj_method_perspective_c, this option
specifies the position for the source of rays needed to
define the perspective projection.
'bidirectional' Whether 'curves' should be projected in the positive and
negative 'direction'. Only valid for vector projection.
See here for more information.
'use_max_dist' Whether to restrict the projection to be within 'max_dist'
of the input curve. This option is not supported if
'method' is PK_proj_method_vector_c to surfaces.
See here for more information.
'max_dist' If 'use_max_dist' is set to PK_proj_max_dist_whole_c,
this field contains the maximum allowed distance of the
projected curve from its input. The distance is measured
along the projection direction.
'hidden' How to project to hidden faces. Only valid for
projection to faces or bodies. See here
for more information.
'connect' How to connect disjoint projections. Only valid for vector
projection to faces or bodies. See here for more
information.
'banned_classes' If this array is empty, the output curves may be of any
class. Otherwise, curves of classes contained in this array
will be converted to B-curves, or SP-curves if B-curves are
themselves forbidden. Note that this array may not contain
both PK_CLASS_bcurve and PK_CLASS_spcurve, and that this
array may not contain PK_CLASS_pline.
Note: if 'function' is set to an imprinting operation, this
option does not control the class of the resulting edge or
fin geometry.
'split_clash' How to split output curves at self-intersections and
clashes. If not split, these will be reported in a
PK_REPORT_3_proj_cu_split_c record. See here
for more information.
'create_points' How to project curves to produce points for point-
like projections, or vertices for point-like imprints. See
here for more information.
'construction' Whether to add the output curves and points as construction
geometry to the body. If this option is PK_LOGICAL_false,
or if projection is to a surface, the function will produce
orphan geometry. This is in addition to nominal geometry on
tolerant edges, as determined by the 'nominal' option.
The default value is PK_LOGICAL_true.
'tolerance' The operation tolerance for the projection and imprinting.
It is used to resolve clashes (between geometries and
topologies) and for curve fitting if necessary.
'function' Whether to perform a pure projection, a pure imprint,
or both an imprint and a projection. The default is
PK_proj_function_project_c. If a non-default value is
chosen, 'split_clash' must be set to
PK_proj_split_clash_all_c.
'imprint_precision' How to set the precision of the imprinted topology.
This option only has an effect if 'function' is set to
an imprinting operation.
The default value is PK_imprint_precision_auto_c.
'nominal' Whether to attach the projected curve as nominal
geometry to imprinted tolerant edges. A non-default
value is only permitted if an imprinting operation has been
specified in 'function'. If 'function' has the value
PK_proj_function_both_c, the nominal geometry is in
addition to any orphan or construction geometry controlled
by the 'construction' option.
The default value is PK_proj_nominal_no_c.
'complete' How to complete the imprinted edges so that the end
vertices of the imprint lie on an edge or laminar edge of
the target. The default value is PK_proj_complete_no_c.
A non-default value is only permitted if an imprinting
operation has been set in 'function', and if no
'banned_classes' have been specified.
'complete_bound' How to bound imprint completion. The default
(PK_complete_bound_none_c) is unbounded.
A non-default value is only permitted if the 'complete'
option has been set to a non-default value.
'complete_bound_distance'
The distance used to bound imprint completion, as
determined by 'complete_bound'. If 'complete_bound'
has a non-default value, then 'complete_bound_distance'
must be greater than 'tolerance'.
'update' The default value (PK_proj_update_default_c) allows
applications to take advantage of the latest enhancements
to the algorithm. To maintain consistency when rebuilding
models created in a previous version of Parasolid, a
non-default value should be specified.
'tracking' Determines the format of the tracking records.
The default value (PK_proj_tracking_basic_c) provides
minimal tracking of imprint completion edges.
'results_output' Specifies whether the function should output its
results as return arguments from the function,
or in report form to the Parasolid report. The records
in the report will be of type PK_REPORT_record_type_3_c.
Possible values are:
PK_results_output_return_c:
The results are output in the 'return' and
'tracking' arguments to the function.
This is the default.
PK_results_output_report_c:
The 'return' and 'tracking' structures remain
empty. If the function returns PK_ERROR_no_errors
the results are output in the Parasolid report. A
single record with status PK_REPORT_3_proj_cu_map_c
will contain all the projection results.
'want_orig_intervals'
Specifies whether the originating intervals are computed
for each projection. This is the interval on the input
curve which contributed to a projection or imprint.
Such intervals are only defined for direct imprints (not
imprint completion edges) and can only be returned in the
Parasolid report (i.e. only if results_output is set to
PK_results_output_report_c).
The default value is PK_LOGICAL_false.
The tables below show which options are available for each value of
'function' and 'method'. An "X" indicates that the option may take non-default
values.
+-----------------------------------+
| PK_proj_function_t |
+-----------+-----------+-----------+
| project | imprint | both |
+--------------------+-----------+-----------+-----------+
| bidirectional | X | X | X |
| use_max_dist | X | X | X |
| hidden | X | X | X |
| connect | X | X | X |
| banned_classes | X | X | X |
| split_clash | X | | |
| create_points | X | X | X |
| construction | X | | X |
| tolerance | X | X | X |
| imprint_precision | | X | X |
| nominal | | X | X |
| complete | | X | X |
| complete_bound | | X | X |
| tracking | X | X | X |
| results_output | X | X | X |
| want_orig_intervals| X | X | X |
+--------------------+-----------+-----------+-----------+
+-----------------------------------------+
| PK_proj_method_t |
+-----------+-----------+-----------------+
| normal | vector | perspective |
+--------------------+-----------+-----------+-----------------+
| bidirectional | | X | |
| use_max_dist | X | X | |
| hidden | X | X | |
| connect | | X | |
| banned_classes | X | X | X |
| split_clash | X | X | X |
| create_points | X | X | X |
| construction | X | X | X |
| tolerance | X | X | X |
| imprint_precision | X | X | X |
| nominal | X | X | X |
| complete | X | X | X |
| complete_bound | X | X | X |
| tracking | X | X | X |
| results_output | X | X | X |
| want_orig_intervals| X | X | X |
+--------------------+-----------+-----------+-----------------+