gen_rectangle2gen_rectangle2GenRectangle2GenRectangle2gen_rectangle2 (Operator)

Name

gen_rectangle2gen_rectangle2GenRectangle2GenRectangle2gen_rectangle2 — Erzeugen eines beliebig orientierten Rechtecks.

Signatur

gen_rectangle2( : Rectangle : Row, Column, Phi, Length1, Length2 : )

Herror gen_rectangle2(Hobject* Rectangle, double Row, double Column, double Phi, double Length1, double Length2)

Herror T_gen_rectangle2(Hobject* Rectangle, const Htuple Row, const Htuple Column, const Htuple Phi, const Htuple Length1, const Htuple Length2)

void GenRectangle2(HObject* Rectangle, const HTuple& Row, const HTuple& Column, const HTuple& Phi, const HTuple& Length1, const HTuple& Length2)

void HRegion::GenRectangle2(const HTuple& Row, const HTuple& Column, const HTuple& Phi, const HTuple& Length1, const HTuple& Length2)

void HRegion::GenRectangle2(double Row, double Column, double Phi, double Length1, double Length2)

static void HOperatorSet.GenRectangle2(out HObject rectangle, HTuple row, HTuple column, HTuple phi, HTuple length1, HTuple length2)

void HRegion.GenRectangle2(HTuple row, HTuple column, HTuple phi, HTuple length1, HTuple length2)

void HRegion.GenRectangle2(double row, double column, double phi, double length1, double length2)

def gen_rectangle2(row: MaybeSequence[Union[int, float]], column: MaybeSequence[Union[int, float]], phi: MaybeSequence[Union[int, float]], length_1: MaybeSequence[Union[int, float]], length_2: MaybeSequence[Union[int, float]]) -> HObject

Beschreibung

gen_rectangle2gen_rectangle2GenRectangle2GenRectangle2GenRectangle2gen_rectangle2 generiert ein oder mehrere Rechtecke mit dem Schwerpunkt (RowRowRowRowrowrow, ColumnColumnColumnColumncolumncolumn) , der Orientierung PhiPhiPhiPhiphiphi und den halben Kantenlängen Length1Length1Length1Length1length1length_1 und Length2Length2Length2Length2length2length_2. Die Orientierung wird in Bogenmaß angegeben und gibt den Winkel zwischen der horizontalen Achse und der ersten Kante (mit Länge Length1Length1Length1Length1length1length_1) an (mathematisch positiv). Das Koordinatensystem läuft von (0,0) (linkes oberes Eck) bis (Width-1,Height-1). Siehe hierzu auch get_systemget_systemGetSystemGetSystemGetSystemget_system und reset_obj_dbreset_obj_dbResetObjDbResetObjDbResetObjDbreset_obj_db. Es kann mehr als eine Region erzeugt werden, indem ein Tupel von Eckpunkten übergeben wird.

Achtung

Die Grauwerte der Ausgabeobjekte sind undefiniert. Aus Geschwindigkeitsgründen kann die Ergebnisregion zusätzliche Pixel am Rand enthalten, und einige einzelne Pixel am Rand können fehlen. Dies kann zu einer Inkonsistenz zwischen den Operatoren smallest_rectangle2smallest_rectangle2SmallestRectangle2SmallestRectangle2SmallestRectangle2smallest_rectangle2 und gen_rectangle2gen_rectangle2GenRectangle2GenRectangle2GenRectangle2gen_rectangle2 führen.

Ausführungsinformationen

Parameter

RectangleRectangleRectangleRectanglerectanglerectangle (output_object)  region(-array) objectHRegionHObjectHRegionHobject *

Erzeugtes Rechteck.

RowRowRowRowrowrow (input_control)  rectangle2.center.y(-array) HTupleMaybeSequence[Union[int, float]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Zeilenindex des Schwerpunktes.

Defaultwert: 300.0

Wertevorschläge: 10.0, 20.0, 50.0, 100.0, 200.0, 300.0, 400.0, 500.0

Typischer Wertebereich: Row Row Row Row row row (lin)

Minimale Schrittweite: 1.0

Empfohlene Schrittweite: 10.0

ColumnColumnColumnColumncolumncolumn (input_control)  rectangle2.center.x(-array) HTupleMaybeSequence[Union[int, float]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Spaltenindex des Schwerpunktes.

Defaultwert: 200.0

Wertevorschläge: 10.0, 20.0, 50.0, 100.0, 200.0, 300.0, 400.0, 500.0

Typischer Wertebereich: Column Column Column Column column column (lin)

Minimale Schrittweite: 1.0

Empfohlene Schrittweite: 10.0

PhiPhiPhiPhiphiphi (input_control)  rectangle2.angle.rad(-array) HTupleMaybeSequence[Union[int, float]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Winkel der ersten Kante zur Horizontalen (Bogenmaß).

Defaultwert: 0.0

Wertevorschläge: -1.178097, -0.785398, -0.392699, 0.0, 0.392699, 0.785398, 1.178097

Typischer Wertebereich: Phi Phi Phi Phi phi phi (lin)

Restriktion: - pi / 2 < Phi && Phi <= pi / 2

Length1Length1Length1Length1length1length_1 (input_control)  rectangle2.hwidth(-array) HTupleMaybeSequence[Union[int, float]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Halbe Breite.

Defaultwert: 100.0

Wertevorschläge: 3.0, 5.0, 10.0, 15.0, 20.0, 50.0, 100.0, 200.0, 300.0, 500.0

Typischer Wertebereich: Length1 Length1 Length1 Length1 length1 length_1 (lin)

Minimale Schrittweite: 1.0

Empfohlene Schrittweite: 10.0

Length2Length2Length2Length2length2length_2 (input_control)  rectangle2.hheight(-array) HTupleMaybeSequence[Union[int, float]]HTupleHtuple (real / integer) (double / int / long) (double / Hlong) (double / Hlong)

Halbe Höhe.

Defaultwert: 20.0

Wertevorschläge: 1.0, 2.0, 3.0, 5.0, 10.0, 15.0, 20.0, 50.0, 100.0, 200.0

Typischer Wertebereich: Length2 Length2 Length2 Length2 length2 length_2 (lin)

Minimale Schrittweite: 1.0

Empfohlene Schrittweite: 10.0

Ergebnis

Sind die Parameterwerte korrekt, dann liefert gen_rectangle2gen_rectangle2GenRectangle2GenRectangle2GenRectangle2gen_rectangle2 den Wert 2 (H_MSG_TRUE). Andernfalls wird eine Fehlerbehandlung durchgeführt. Das Clipping am aktuellen Bildformat wird durch set_system('clip_region',<'true'/'false'>)set_system("clip_region",<"true"/"false">)SetSystem("clip_region",<"true"/"false">)SetSystem("clip_region",<"true"/"false">)SetSystem("clip_region",<"true"/"false">)set_system("clip_region",<"true"/"false">) festgelegt.

Nachfolger

paint_regionpaint_regionPaintRegionPaintRegionPaintRegionpaint_region, reduce_domainreduce_domainReduceDomainReduceDomainReduceDomainreduce_domain

Alternativen

gen_rectangle1gen_rectangle1GenRectangle1GenRectangle1GenRectangle1gen_rectangle1, gen_region_polygon_filledgen_region_polygon_filledGenRegionPolygonFilledGenRegionPolygonFilledGenRegionPolygonFilledgen_region_polygon_filled, gen_region_polygongen_region_polygonGenRegionPolygonGenRegionPolygonGenRegionPolygongen_region_polygon, gen_region_pointsgen_region_pointsGenRegionPointsGenRegionPointsGenRegionPointsgen_region_points, fill_upfill_upFillUpFillUpFillUpfill_up

Siehe auch

draw_rectangle2draw_rectangle2DrawRectangle2DrawRectangle2DrawRectangle2draw_rectangle2, reduce_domainreduce_domainReduceDomainReduceDomainReduceDomainreduce_domain, smallest_rectangle2smallest_rectangle2SmallestRectangle2SmallestRectangle2SmallestRectangle2smallest_rectangle2, gen_ellipsegen_ellipseGenEllipseGenEllipseGenEllipsegen_ellipse

Modul

Foundation