spatial_relationT_spatial_relationSpatialRelationSpatialRelationspatial_relation (Operator)

Name

spatial_relationT_spatial_relationSpatialRelationSpatialRelationspatial_relation — Ermitteln der Lagebeziehung von Regionen bzgl. der Koordinatenachsen.

Signatur

spatial_relation(Regions1, Regions2 : : Percent : RegionIndex1, RegionIndex2, Relation1, Relation2)

Herror T_spatial_relation(const Hobject Regions1, const Hobject Regions2, const Htuple Percent, Htuple* RegionIndex1, Htuple* RegionIndex2, Htuple* Relation1, Htuple* Relation2)

void SpatialRelation(const HObject& Regions1, const HObject& Regions2, const HTuple& Percent, HTuple* RegionIndex1, HTuple* RegionIndex2, HTuple* Relation1, HTuple* Relation2)

HTuple HRegion::SpatialRelation(const HRegion& Regions2, Hlong Percent, HTuple* RegionIndex2, HTuple* Relation1, HTuple* Relation2) const

static void HOperatorSet.SpatialRelation(HObject regions1, HObject regions2, HTuple percent, out HTuple regionIndex1, out HTuple regionIndex2, out HTuple relation1, out HTuple relation2)

HTuple HRegion.SpatialRelation(HRegion regions2, int percent, out HTuple regionIndex2, out HTuple relation1, out HTuple relation2)

def spatial_relation(regions_1: HObject, regions_2: HObject, percent: int) -> Tuple[Sequence[int], Sequence[int], Sequence[str], Sequence[str]]

Beschreibung

spatial_relationspatial_relationSpatialRelationSpatialRelationSpatialRelationspatial_relation wählt Regionen aus, die um PercentPercentPercentPercentpercentpercent Prozent „links“, „rechts“, „oberhalb“ oder „unterhalb“ von anderen Regionen liegen. Regions1Regions1Regions1Regions1regions1regions_1 und Regions2Regions2Regions2Regions2regions2regions_2 enthalten die zu vergleichenden Regionen. Regions1Regions1Regions1Regions1regions1regions_1 kann dabei auf drei verschiedene Arten besetzt werden:

Der Prozentsatz PercentPercentPercentPercentpercentpercent wird so interpretiert, dass die Fläche der zweiten Region um mindestens PercentPercentPercentPercentpercentpercent Prozent echt links/rechts bzw. oberhalb/unterhalb der Regionengrenzen der ersten Region liegen muss. Die Indizes der Regionen, die mindestens eine dieser Bedingungen erfüllen, stehen dann an n-ter Position in den Ausgabeparametern RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1 und RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2. Zusätzlich enthalten die Ausgabeparameter Relation1Relation1Relation1Relation1relation1relation_1 und Relation2Relation2Relation2Relation2relation2relation_2 an n-ter Position die Art der Relation, in der das Regionenpaar (RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1[n], RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2[n]) steht, d.h. Region mit Index RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2[n] steht mit Region mit Index RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1[n] in der Relation1Relation1Relation1Relation1relation1relation_1[n] und Relation2Relation2Relation2Relation2relation2relation_2[n].

Mögliche Werte für Relation1Relation1Relation1Relation1relation1relation_1 und Relation2Relation2Relation2Relation2relation2relation_2 sind:

In RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1 und RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2 werden die Indizes der Regionen in den Tupeln der Eingaberegionen (Regions1Regions1Regions1Regions1regions1regions_1 bzw. Regions2Regions2Regions2Regions2regions2regions_2) als Bildidentifikatoren eingetragen. Der Zugriff auf ausgewählte Regionen über den Index kann mit copy_objcopy_objCopyObjCopyObjCopyObjcopy_obj erfolgen.

Ausführungsinformationen

Parameter

Regions1Regions1Regions1Regions1regions1regions_1 (input_object)  region(-array) objectHRegionHObjectHRegionHobject

Ausgangsregionen.

Regions2Regions2Regions2Regions2regions2regions_2 (input_object)  region(-array) objectHRegionHObjectHRegionHobject

Vergleichsregionen.

PercentPercentPercentPercentpercentpercent (input_control)  integer HTupleintHTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Prozentzahl der Fläche der Vergleichsregion, die links/rechts bzw. oberhalb/unterhalb der Regionengrenzen der Ausgangsregion liegen muss.

Defaultwert: 50

Wertevorschläge: 0, 10, 20, 30, 40, 50, 60, 70, 80, 90, 100

Typischer Wertebereich: 0 ≤ Percent Percent Percent Percent percent percent ≤ 100 (lin)

Minimale Schrittweite: 1

Empfohlene Schrittweite: 10

RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1 (output_control)  integer-array HTupleSequence[int]HTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Indizes der Regionen im Tupel der Eingaberegionen, die die Lagerelation erfüllen.

RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2 (output_control)  integer-array HTupleSequence[int]HTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Indizes der Regionen im Tupel der Eingaberegionen, die die Lagerelation erfüllen.

Relation1Relation1Relation1Relation1relation1relation_1 (output_control)  string-array HTupleSequence[str]HTupleHtuple (string) (string) (HString) (char*)

Vertikale Lagerelation, in der RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2[n] mit RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1[n] steht.

Relation2Relation2Relation2Relation2relation2relation_2 (output_control)  string-array HTupleSequence[str]HTupleHtuple (string) (string) (HString) (char*)

Horizontale Lagerelation, in der RegionIndex2RegionIndex2RegionIndex2RegionIndex2regionIndex2region_index_2[n] mit RegionIndex1RegionIndex1RegionIndex1RegionIndex1regionIndex1region_index_1[n] steht.

Ergebnis

spatial_relationspatial_relationSpatialRelationSpatialRelationSpatialRelationspatial_relation liefert den Wert 2 (H_MSG_TRUE), falls Regions2Regions2Regions2Regions2regions2regions_2 nicht leer und PercentPercentPercentPercentpercentpercent korrekt besetzt ist. Das Verhalten bei leerem Parameter Regions2Regions2Regions2Regions2regions2regions_2 (keine Eingaberegionen vorhanden) lässt sich mittels set_system('no_object_result',<Result>)set_system("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)SetSystem("no_object_result",<Result>)set_system("no_object_result",<Result>) festlegen. Das Verhalten bei einer leeren Region (Region ist die leere Menge) wird mit set_system('empty_region_result',<Result>)set_system("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)SetSystem("empty_region_result",<Result>)set_system("empty_region_result",<Result>) bestimmt. Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Vorgänger

thresholdthresholdThresholdThresholdThresholdthreshold, regiongrowingregiongrowingRegiongrowingRegiongrowingRegiongrowingregiongrowing, connectionconnectionConnectionConnectionConnectionconnection

Alternativen

area_centerarea_centerAreaCenterAreaCenterAreaCenterarea_center, intersectionintersectionIntersectionIntersectionIntersectionintersection

Siehe auch

select_region_spatialselect_region_spatialSelectRegionSpatialSelectRegionSpatialSelectRegionSpatialselect_region_spatial, find_neighborsfind_neighborsFindNeighborsFindNeighborsFindNeighborsfind_neighbors, copy_objcopy_objCopyObjCopyObjCopyObjcopy_obj, obj_to_integerobj_to_integerObjToIntegerObjToIntegerObjToIntegerobj_to_integer

Modul

Foundation