Table of Contents

Method Divide

Namespace
GeometryHelper.Meshing
Assembly
GeometryHelper.dll

Divide(GeoRectangle2, int, int)

Divides a rectangle into equal rectangles along its own sides.

public static GeoRectangle2[] Divide(GeoRectangle2 rectangle, int columns, int rows)

Parameters

rectangle GeoRectangle2

The rectangle.

columns int

How many across its width.

rows int

How many across its height.

Returns

GeoRectangle2[]

The rectangles, turned as it is, row by row from its lower side and each row from its left: the one at column c and row r is at index r * columns + c.

Exceptions

ArgumentOutOfRangeException

Thrown when the columns or the rows are fewer than one.