gen_parallel_contour_xldgen_parallel_contour_xldGenParallelContourXldGenParallelContourXldgen_parallel_contour_xld (算子名称)
名称
gen_parallel_contour_xldgen_parallel_contour_xldGenParallelContourXldGenParallelContourXldgen_parallel_contour_xld
— Compute the parallel contour of an XLD contour.
参数签名
描述
gen_parallel_contour_xldgen_parallel_contour_xldGenParallelContourXldGenParallelContourXldGenParallelContourXldgen_parallel_contour_xld
computes for each of the input
contours ContoursContoursContoursContourscontourscontours
a parallel contour with distance
DistanceDistanceDistanceDistancedistancedistance
. The resulting contours are returned in
ParallelContoursParallelContoursParallelContoursParallelContoursparallelContoursparallel_contours
. To calculate the parallel contour, the
normal vector of the input contour is needed in every contour point.
The parameter ModeModeModeModemodemode
determines how these normal vectors are
computed. If ModeModeModeModemodemode
= 'gradient'"gradient""gradient""gradient""gradient""gradient", it is assumed
that the input contours are edges, and the normal information is
obtained from the gradient direction of the edge (see
edges_sub_pixedges_sub_pixEdgesSubPixEdgesSubPixEdgesSubPixedges_sub_pix
). For this, the attribute
'edge_direction'"edge_direction""edge_direction""edge_direction""edge_direction""edge_direction" must exist for the input contour
(see get_contour_attrib_xldget_contour_attrib_xldGetContourAttribXldGetContourAttribXldGetContourAttribXldget_contour_attrib_xld
).
If ModeModeModeModemodemode
= 'contour_normal'"contour_normal""contour_normal""contour_normal""contour_normal""contour_normal", a possibly existing
normal information is used to determine the normals. For this, the
contour attribute 'angle'"angle""angle""angle""angle""angle" must exist (see
lines_gausslines_gaussLinesGaussLinesGaussLinesGausslines_gauss
or edges_sub_pixedges_sub_pixEdgesSubPixEdgesSubPixEdgesSubPixedges_sub_pix
). Finally, if
ModeModeModeModemodemode
= 'regression_normal'"regression_normal""regression_normal""regression_normal""regression_normal""regression_normal", the normal vectors are
determined from a local line fit to each contour point. Here, the
normal vectors are oriented such that they point to the right side
of the contour when the contour is traversed from start to end. In
contrast to the first two modes, this mode can be used for all XLD
contours, no matter how they were generated.
运行信息
- Multithreading type: reentrant (runs in parallel with non-exclusive operators).
- Multithreading scope: global (may be called from any thread).
- Processed without parallelization.
参数表
ContoursContoursContoursContourscontourscontours
(input_object) xld_cont-array →
objectHXLDContHObjectHXLDContHobject
Contours to be transformed.
ParallelContoursParallelContoursParallelContoursParallelContoursparallelContoursparallel_contours
(output_object) xld_cont-array →
objectHXLDContHObjectHXLDContHobject *
Parallel contours.
ModeModeModeModemodemode
(input_control) string →
HTuplestrHTupleHtuple (string) (string) (HString) (char*)
Mode, with which the direction information is computed.
Default:
'regression_normal'
"regression_normal"
"regression_normal"
"regression_normal"
"regression_normal"
"regression_normal"
Suggested values:
'gradient'"gradient""gradient""gradient""gradient""gradient", 'contour_normal'"contour_normal""contour_normal""contour_normal""contour_normal""contour_normal", 'regression_normal'"regression_normal""regression_normal""regression_normal""regression_normal""regression_normal"
DistanceDistanceDistanceDistancedistancedistance
(input_control) number →
HTupleUnion[float, int]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)
Distance of the parallel contour.
Default:
1
Suggested values:
0.2, 0.4, 0.6, 0.8, 1, 2, 3, 4, 5, 7, 10, 15, 20, 30, 40, 50
可能的前置算子
gen_contours_skeleton_xldgen_contours_skeleton_xldGenContoursSkeletonXldGenContoursSkeletonXldGenContoursSkeletonXldgen_contours_skeleton_xld
,
lines_gausslines_gaussLinesGaussLinesGaussLinesGausslines_gauss
,
lines_facetlines_facetLinesFacetLinesFacetLinesFacetlines_facet
,
edges_sub_pixedges_sub_pixEdgesSubPixEdgesSubPixEdgesSubPixedges_sub_pix
,
threshold_sub_pixthreshold_sub_pixThresholdSubPixThresholdSubPixThresholdSubPixthreshold_sub_pix
可能的后置算子
gen_polygons_xldgen_polygons_xldGenPolygonsXldGenPolygonsXldGenPolygonsXldgen_polygons_xld
参考其它
get_contour_xldget_contour_xldGetContourXldGetContourXldGetContourXldget_contour_xld
模块
Foundation