union_straight_contours_xld union_straight_contours_xld UnionStraightContoursXld UnionStraightContoursXld union_straight_contours_xld (Operator)
Name
union_straight_contours_xld union_straight_contours_xld UnionStraightContoursXld UnionStraightContoursXld union_straight_contours_xld — Vereinigen von benachbarten geraden Konturen mit ähnlicher Richtung.
Signatur
Herror union_straight_contours_xld (const Hobject Contours , Hobject* UnionContours , double MaxDist , double MaxDiff , double Percent , const char* Mode , const char* Iterations )
Herror T_union_straight_contours_xld (const Hobject Contours , Hobject* UnionContours , const Htuple MaxDist , const Htuple MaxDiff , const Htuple Percent , const Htuple Mode , const Htuple Iterations )
void UnionStraightContoursXld (const HObject& Contours , HObject* UnionContours , const HTuple& MaxDist , const HTuple& MaxDiff , const HTuple& Percent , const HTuple& Mode , const HTuple& Iterations )
HXLDCont HXLDCont ::UnionStraightContoursXld (double MaxDist , double MaxDiff , double Percent , const HString& Mode , const HTuple& Iterations ) const
HXLDCont HXLDCont ::UnionStraightContoursXld (double MaxDist , double MaxDiff , double Percent , const HString& Mode , const HString& Iterations ) const
HXLDCont HXLDCont ::UnionStraightContoursXld (double MaxDist , double MaxDiff , double Percent , const char* Mode , const char* Iterations ) const
HXLDCont HXLDCont ::UnionStraightContoursXld (double MaxDist , double MaxDiff , double Percent , const wchar_t* Mode , const wchar_t* Iterations ) const
(Nur Windows)
static void HOperatorSet .UnionStraightContoursXld (HObject contours , out HObject unionContours , HTuple maxDist , HTuple maxDiff , HTuple percent , HTuple mode , HTuple iterations )
HXLDCont HXLDCont .UnionStraightContoursXld (double maxDist , double maxDiff , double percent , string mode , HTuple iterations )
HXLDCont HXLDCont .UnionStraightContoursXld (double maxDist , double maxDiff , double percent , string mode , string iterations )
Beschreibung
Mit union_straight_contours_xld union_straight_contours_xld UnionStraightContoursXld UnionStraightContoursXld UnionStraightContoursXld union_straight_contours_xld werden die Konturen
Contours Contours Contours Contours contours contours verglichen und unter gewissen Voraussetzungen
vereinigt. In einem Iterationsschritt werden maximal zwei Konturen,
die die entsprechenden Voraussetzungen erfüllen, vereinigt. Mit dem
Parameter Iterations Iterations Iterations Iterations iterations iterations kann gesteuert werden, wie oft dieser
Vereinigungsschritt wiederholt wird.
Zwei Konturen werden vereinigt, wenn deren kürzester
Endpunktabstand (die Endpunkte sind die Fußpunkte der Lote von den
Konturendpunkten auf die optimale Regressionsgerade) kleiner als
MaxDist MaxDist MaxDist MaxDist maxDist max_dist ist und wenn ihre Richtungsdifferenz (bzgl. der
zugehörigen optimalen Regressionsgeraden) kleiner als
MaxDiff MaxDiff MaxDiff MaxDiff maxDiff max_diff (Bogenmaß) ist.
Wenn nur eine der beiden Bedingungen zutrifft, kann die Entscheidung
zugunsten einer Vereinigung durch die Gewichtung Percent Percent Percent Percent percent percent
beeinflusst werden, indem die prozentuale Überschreitung des
angegebenen Grenzwertes gegen die prozentuale Unterschreitung des
anderen Grenzwertes angerechnet wird. Dabei wird der
Endpunktabstand mit Percent Percent Percent Percent percent percent , die Richtungsdifferenz mit
100 - Percent Percent Percent Percent percent percent bewertet.
Das bedeutet, dass zwei Konturen dann vereinigt werden, wenn sie
die folgende Bedingung erfüllen:
Wenn zwei Konturen beispielsweise einen minimalen Endpunktabstand von
5.0 und eine Richtungsdifferenz von 0.5 haben (bei Grenzwerten
MaxDist MaxDist MaxDist MaxDist maxDist max_dist = 4.0 und MaxDiff MaxDiff MaxDiff MaxDiff maxDiff max_diff = 0.625 ),
so weichen beide Werte von den Grenzwerten um 25% ab. Durch die
Wahl von Percent Percent Percent Percent percent percent = 60 % fällt nun der große
Endpunktabstand stärker ins Gewicht als die geringe
Richtungsdifferenz, weshalb die Konturen nicht
vereinigt werden. Wenn in diesem Fall Percent Percent Percent Percent percent percent =
40 % gewählt würde, würden die Konturen vereinigt werden.
Bei Percent Percent Percent Percent percent percent = 100 % geht nur der Endpunktabstand in die
Entscheidung ein, bei Percent Percent Percent Percent percent percent = 0 % geht nur die
Richtungsdifferenz in die Entscheidung ein, bei Percent Percent Percent Percent percent percent =
50 % sind beide Merkmale gleichberechtigt.
Bei parallel verlaufenden Konturen besteht die Gefahr, dass
nebeneinander liegende Konturen vereinigt werden. Soll dieser
Effekt verhindert werden, so muss für Mode Mode Mode Mode mode mode 'noparallel' "noparallel" "noparallel" "noparallel" "noparallel" "noparallel" ,
ansonsten 'paralleltoo' "paralleltoo" "paralleltoo" "paralleltoo" "paralleltoo" "paralleltoo" angegeben werden.
Für 'every' "every" "every" "every" "every" "every" werden die Konturen bedingungslos vereinigt.
Alle anderen Parameter haben in diesem Fall keinen Einfluss.
Für jede durch Vereinigung neu entstandene Kontur werden die
Regressionsgeradenparameter neu berechnet.
Achtung
Bevor Konturen mit union_straight_contours_xld union_straight_contours_xld UnionStraightContoursXld UnionStraightContoursXld UnionStraightContoursXld union_straight_contours_xld vereinigt werden
können, müssen die Regressionsgeradenparameter mit
regress_contours_xld regress_contours_xld RegressContoursXld RegressContoursXld RegressContoursXld regress_contours_xld berechnet werden.
Außerdem ist zu beachten, dass union_straight_contours_xld union_straight_contours_xld UnionStraightContoursXld UnionStraightContoursXld UnionStraightContoursXld union_straight_contours_xld keine
Konturen vereinigen kann, deren Punkte unterschiedliche Attribute aufweisen.
Dieser Fall kann eintreten, wenn Konturen mit verschiedenen Operatoren
extrahiert werden (z.B. mit lines_gauss lines_gauss LinesGauss LinesGauss LinesGauss lines_gauss und lines_facet lines_facet LinesFacet LinesFacet LinesFacet lines_facet ).
Informationen zu den Konturattributen und in welchen Fällen diese definiert
werden, können in den jeweiligen Operatorenreferenzen gefunden werden.
Die Punktattribute einer Kontur können mit query_contour_attribs_xld query_contour_attribs_xld QueryContourAttribsXld QueryContourAttribsXld QueryContourAttribsXld query_contour_attribs_xld
abgefragt werden.
Ausführungsinformationen
Multithreading-Typ: reentrant (läuft parallel zu nicht-exklusiven Operatoren).
Multithreading-Bereich: global (kann von jedem Thread aufgerufen werden).
Wird ohne Parallelisierung verarbeitet.
Parameter
Contours Contours Contours Contours contours contours (input_object) xld_cont-array → object HXLDCont HObject HXLDCont Hobject
Eingabe-Konturen.
UnionContours UnionContours UnionContours UnionContours unionContours union_contours (output_object) xld_cont-array → object HXLDCont HObject HXLDCont Hobject *
Ausgabe-Konturen.
MaxDist MaxDist MaxDist MaxDist maxDist max_dist (input_control) real → HTuple float HTuple Htuple (real) (double ) (double ) (double )
Maximaler Abstand der Endpunkte.
Defaultwert: 5.0
MaxDiff MaxDiff MaxDiff MaxDiff maxDiff max_diff (input_control) angle.rad → HTuple float HTuple Htuple (real) (double ) (double ) (double )
Maximale Richtungsdifferenz.
Defaultwert: 0.5
Percent Percent Percent Percent percent percent (input_control) real → HTuple float HTuple Htuple (real) (double ) (double ) (double )
Gewichtungsfaktor für die zwei Selektionskriterien.
Defaultwert: 50.0
Mode Mode Mode Mode mode mode (input_control) string → HTuple str HTuple Htuple (string) (string ) (HString ) (char* )
Berücksichtigung paralleler Konturen.
Defaultwert:
'noparallel'
"noparallel"
"noparallel"
"noparallel"
"noparallel"
"noparallel"
Werteliste: 'every' "every" "every" "every" "every" "every" , 'noparallel' "noparallel" "noparallel" "noparallel" "noparallel" "noparallel" , 'paralleltoo' "paralleltoo" "paralleltoo" "paralleltoo" "paralleltoo" "paralleltoo"
Iterations Iterations Iterations Iterations iterations iterations (input_control) string → HTuple Union[int, str] HTuple Htuple (string / integer) (string / int / long) (HString / Hlong) (char* / Hlong)
Anzahl Iterationen oder 'maximum'.
Defaultwert:
'maximum'
"maximum"
"maximum"
"maximum"
"maximum"
"maximum"
Wertevorschläge: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 'maximum' "maximum" "maximum" "maximum" "maximum" "maximum"
Typischer Wertebereich: 1
≤
Iterations
Iterations
Iterations
Iterations
iterations
iterations
≤
500 (lin)
Minimale Schrittweite: 1
Empfohlene Schrittweite: 1
Vorgänger
regress_contours_xld regress_contours_xld RegressContoursXld RegressContoursXld RegressContoursXld regress_contours_xld
Alternativen
union_collinear_contours_xld union_collinear_contours_xld UnionCollinearContoursXld UnionCollinearContoursXld UnionCollinearContoursXld union_collinear_contours_xld ,
union_collinear_contours_ext_xld union_collinear_contours_ext_xld UnionCollinearContoursExtXld UnionCollinearContoursExtXld UnionCollinearContoursExtXld union_collinear_contours_ext_xld ,
union_cocircular_contours_xld union_cocircular_contours_xld UnionCocircularContoursXld UnionCocircularContoursXld UnionCocircularContoursXld union_cocircular_contours_xld ,
union_cotangential_contours_xld union_cotangential_contours_xld UnionCotangentialContoursXld UnionCotangentialContoursXld UnionCotangentialContoursXld union_cotangential_contours_xld ,
union_adjacent_contours_xld union_adjacent_contours_xld UnionAdjacentContoursXld UnionAdjacentContoursXld UnionAdjacentContoursXld union_adjacent_contours_xld
Siehe auch
fit_line_contour_xld fit_line_contour_xld FitLineContourXld FitLineContourXld FitLineContourXld fit_line_contour_xld ,
get_contour_xld get_contour_xld GetContourXld GetContourXld GetContourXld get_contour_xld ,
get_contour_attrib_xld get_contour_attrib_xld GetContourAttribXld GetContourAttribXld GetContourAttribXld get_contour_attrib_xld ,
gen_contours_skeleton_xld gen_contours_skeleton_xld GenContoursSkeletonXld GenContoursSkeletonXld GenContoursSkeletonXld gen_contours_skeleton_xld ,
lines_gauss lines_gauss LinesGauss LinesGauss LinesGauss lines_gauss ,
lines_facet lines_facet LinesFacet LinesFacet LinesFacet lines_facet ,
edges_sub_pix edges_sub_pix EdgesSubPix EdgesSubPix EdgesSubPix edges_sub_pix ,
get_regress_params_xld get_regress_params_xld GetRegressParamsXld GetRegressParamsXld GetRegressParamsXld get_regress_params_xld ,
get_contour_global_attrib_xld get_contour_global_attrib_xld GetContourGlobalAttribXld GetContourGlobalAttribXld GetContourGlobalAttribXld get_contour_global_attrib_xld ,
query_contour_global_attribs_xld query_contour_global_attribs_xld QueryContourGlobalAttribsXld QueryContourGlobalAttribsXld QueryContourGlobalAttribsXld query_contour_global_attribs_xld
Modul
Foundation