gen_region_polygonT_gen_region_polygonGenRegionPolygonGenRegionPolygongen_region_polygon (Operator)

Name

gen_region_polygonT_gen_region_polygonGenRegionPolygonGenRegionPolygongen_region_polygon — Abspeichern eines Polygons als Region.

Signatur

gen_region_polygon( : Region : Rows, Columns : )

Herror T_gen_region_polygon(Hobject* Region, const Htuple Rows, const Htuple Columns)

void GenRegionPolygon(HObject* Region, const HTuple& Rows, const HTuple& Columns)

void HRegion::GenRegionPolygon(const HTuple& Rows, const HTuple& Columns)

static void HOperatorSet.GenRegionPolygon(out HObject region, HTuple rows, HTuple columns)

void HRegion.GenRegionPolygon(HTuple rows, HTuple columns)

def gen_region_polygon(rows: Sequence[int], columns: Sequence[int]) -> HObject

Beschreibung

gen_region_polygongen_region_polygonGenRegionPolygonGenRegionPolygonGenRegionPolygongen_region_polygon erzeugt eine Region aus einem Polygonzug, der durch eine Folge von Zeilen- und Spaltenkoordinaten beschrieben wird. Die erzeugte Region besteht aus den Punkten der dadurch definierten Strecken, wobei zwischen den Stützpunkten linear interpoliert wird.

Achtung

Die Region wird nicht automatisch geschlossen und nicht „aufgefüllt“.

Ausführungsinformationen

Parameter

RegionRegionRegionRegionregionregion (output_object)  region objectHRegionHObjectHRegionHobject *

Erzeugte Region.

RowsRowsRowsRowsrowsrows (input_control)  polygon.y-array HTupleSequence[int]HTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Zeilenindizes der Stützpunkte der Regionenkontur.

Defaultwert: 100

Wertevorschläge: 0, 10, 30, 50, 100, 200, 300, 500

Typischer Wertebereich: Rows Rows Rows Rows rows rows (lin)

Minimale Schrittweite: 1

Empfohlene Schrittweite: 1

ColumnsColumnsColumnsColumnscolumnscolumns (input_control)  polygon.x-array HTupleSequence[int]HTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Spaltenindizes der Stützpunkte der Regionenkontur.

Parameteranzahl: Columns == Rows

Defaultwert: 100

Wertevorschläge: 0, 10, 30, 50, 100, 200, 300, 500

Typischer Wertebereich: Columns Columns Columns Columns columns columns (lin)

Minimale Schrittweite: 1

Empfohlene Schrittweite: 1

Beispiel (HDevelop)

* Polygon-approximation
get_region_polygon(Region,7,Row,Column)
* store it as a region
gen_region_polygon(Pol,Row,Column)
* fill up the hole
fill_up(Pol,Filled)

Beispiel (C)

/* Polygon-approximation */
T_get_region_polygon(Region,7,&Row,&Column);
/* store it as a region */
T_gen_region_polygon(&Pol,Row,Column);
destroy_tuple(Row);
destroy_tuple(Column);
/* fill up the hole */
fill_up(Pol,&Filled);

Beispiel (HDevelop)

* Polygon-approximation
get_region_polygon(Region,7,Row,Column)
* store it as a region
gen_region_polygon(Pol,Row,Column)
* fill up the hole
fill_up(Pol,Filled)

Beispiel (HDevelop)

* Polygon-approximation
get_region_polygon(Region,7,Row,Column)
* store it as a region
gen_region_polygon(Pol,Row,Column)
* fill up the hole
fill_up(Pol,Filled)

Beispiel (HDevelop)

* Polygon-approximation
get_region_polygon(Region,7,Row,Column)
* store it as a region
gen_region_polygon(Pol,Row,Column)
* fill up the hole
fill_up(Pol,Filled)

Ergebnis

Falls die Stützpunkte korrekt sind, liefert gen_region_polygongen_region_polygonGenRegionPolygonGenRegionPolygonGenRegionPolygongen_region_polygon den Wert TRUE. Andernfalls wird eine Fehlerbehandlung durchgeführt. Das Clipping am aktuellen Bildformat wird durch set_system('clip_region',<'2 (H_MSG_TRUE)'/'3 (H_MSG_FALSE)'>)set_system("clip_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)SetSystem("clip_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)SetSystem("clip_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)SetSystem("clip_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">)set_system("clip_region",<"2 (H_MSG_TRUE)"/"3 (H_MSG_FALSE)">) festgelegt. Wird eine leere Region erzeugt (durch das Clipping oder eine leere Eingabe), dann legt 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)">) fest, ob die Region ausgegeben wird.

Vorgänger

get_region_polygonget_region_polygonGetRegionPolygonGetRegionPolygonGetRegionPolygonget_region_polygon, draw_polygondraw_polygonDrawPolygonDrawPolygonDrawPolygondraw_polygon

Alternativen

gen_region_polygon_filledgen_region_polygon_filledGenRegionPolygonFilledGenRegionPolygonFilledGenRegionPolygonFilledgen_region_polygon_filled, gen_region_pointsgen_region_pointsGenRegionPointsGenRegionPointsGenRegionPointsgen_region_points, gen_region_runsgen_region_runsGenRegionRunsGenRegionRunsGenRegionRunsgen_region_runs

Siehe auch

fill_upfill_upFillUpFillUpFillUpfill_up, reduce_domainreduce_domainReduceDomainReduceDomainReduceDomainreduce_domain, get_region_polygonget_region_polygonGetRegionPolygonGetRegionPolygonGetRegionPolygonget_region_polygon, draw_polygondraw_polygonDrawPolygonDrawPolygonDrawPolygondraw_polygon

Modul

Foundation