partition_rectanglepartition_rectanglePartitionRectanglePartitionRectanglepartition_rectangle (Operator)

Name

partition_rectanglepartition_rectanglePartitionRectanglePartitionRectanglepartition_rectangle — Aufteilen einer Region in Rechtecke von ungefähr gleicher Größe.

Signatur

partition_rectangle(Region : Partitioned : Width, Height : )

Herror partition_rectangle(const Hobject Region, Hobject* Partitioned, double Width, double Height)

Herror T_partition_rectangle(const Hobject Region, Hobject* Partitioned, const Htuple Width, const Htuple Height)

void PartitionRectangle(const HObject& Region, HObject* Partitioned, const HTuple& Width, const HTuple& Height)

HRegion HRegion::PartitionRectangle(double Width, double Height) const

static void HOperatorSet.PartitionRectangle(HObject region, out HObject partitioned, HTuple width, HTuple height)

HRegion HRegion.PartitionRectangle(double width, double height)

def partition_rectangle(region: HObject, width: float, height: float) -> HObject

Beschreibung

partition_rectanglepartition_rectanglePartitionRectanglePartitionRectanglePartitionRectanglepartition_rectangle zerlegt die Eingaberegion in Rechtecke der Größe WidthWidthWidthWidthwidthwidth mal HeightHeightHeightHeightheightheight. Die Rechtecke werden in PartitionedPartitionedPartitionedPartitionedpartitionedpartitioned zurückgeliefert. Die Region wird immer in etwa gleich große Rechtecke zerlegt. Falls dies mit der gewünschten Rechteckgröße nicht möglich ist, werden WidthWidthWidthWidthwidthwidth und HeightHeightHeightHeightheightheight so angepasst, dass die resultierenden Rechtecke in etwa gleich groß sind. Wenn die Region kleiner als die angegebene Größe ist, bleibt sie unverändert. Eine Zerlegung findet erst statt, wenn die Größe mindestens 1.5 mal so groß ist wie durch die Parameter vorgegeben.

Ausführungsinformationen

Parameter

RegionRegionRegionRegionregionregion (input_object)  region(-array) objectHRegionHObjectHRegionHobject

Region die zerlegt werden soll.

PartitionedPartitionedPartitionedPartitionedpartitionedpartitioned (output_object)  region(-array) objectHRegionHObjectHRegionHobject *

Zerlegte Region.

WidthWidthWidthWidthwidthwidth (input_control)  extent.x HTuplefloatHTupleHtuple (real) (double) (double) (double)

Breite der einzelnen Rechtecke.

HeightHeightHeightHeightheightheight (input_control)  extent.y HTuplefloatHTupleHtuple (real) (double) (double) (double)

Höhe der einzelnen Rechtecke.

Ergebnis

partition_rectanglepartition_rectanglePartitionRectanglePartitionRectanglePartitionRectanglepartition_rectangle liefert normalerweise den Wert TRUE. Das Verhalten bei leerer Eingabe (keine Eingabebilder 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>), das bei leerer Region 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>), das bei leerer Ergebnisregion mit set_system('store_empty_region',<'2 (H_MSG_TRUE)'/'3 (H_MSG_FALSE)'>)set_system("store_empty_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)SetSystem("store_empty_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)SetSystem("store_empty_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)SetSystem("store_empty_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)set_system("store_empty_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">) festlegen. Gegebenenfalls wird eine Fehlerbehandlung durchgeführt.

Vorgänger

thresholdthresholdThresholdThresholdThresholdthreshold, connectionconnectionConnectionConnectionConnectionconnection

Alternativen

partition_dynamicpartition_dynamicPartitionDynamicPartitionDynamicPartitionDynamicpartition_dynamic

Siehe auch

intersectionintersectionIntersectionIntersectionIntersectionintersection, smallest_rectangle1smallest_rectangle1SmallestRectangle1SmallestRectangle1SmallestRectangle1smallest_rectangle1, shape_transshape_transShapeTransShapeTransShapeTransshape_trans, clip_regionclip_regionClipRegionClipRegionClipRegionclip_region

Modul

Foundation