Please enable JavaScript to view this site.

Knowledge Base

This function adds a polygon element to a GDSII file stream. Polygons are also known as boundary elements in GDS terminology. This command can be called only if a cell has been created.

 

Supported Product: FDTD, MODE, DEVICE, INTERCONNECT

 

Syntax

Description

gdsaddpoly(f, layer, [vertices])

Adds a polygon element on a layer with vertices.

 

Parameter

Type

Description

f

string

a file handle that was previously opened with gdsopen.

layer

string or number

string: a string of the form "layer:datatype" (for example "6:2") can be used to define the layer number and datatype for this structure from the GDSII file to import. Layer and datatype are integers.

 

number: defines the layer number and sets the datatype to be zero.

vertices

matrix

vertices of the polygon, in a Nx2 matrix where the first column represents x and the second column represents y, e.g., [x1,y1; x2,y2;...xn,yn]. The values are in meters. The first and last values should not be the same, the polygon will be automatically closed.

 

Example

An example of script code is available on the gdsopen page.

 

See Also

gdsopen, gdsclose, gdsbegincell, gdsendcell, gdsaddcircle, gdsaddref, gdsimport

Copyright Lumerical Inc. | Privacy | Site Map