Path

class ipkiss3.all.Path

Layout element consisting of a closed or open Shape drawn on a given Layer with a given line width

Parameters:
line_width: required
shape: Shape, required
layer: __Layer__, required

Layout layer on which the element needs to be placed

extension: tuple2 and Tuple of <class ‘float’>, optional

extension of the path at start and end: (start, end)

absolute_line_width: ( bool, bool_ or int ), optional
path_type: List with value restriction, allowed values: [0, 1, 2, 4], optional
transformation: GenericNoDistortTransform, optional

Examples

# Shows how to use the different path types: NORMAL, ROUNDED, EXTENDED, VARIABLE
import ipkiss3.all as i3

# Define new layer
process = i3.ProcessLayer(name="process", extension="PROC")
layer = i3.PPLayer(process=process, purpose=i3.TECH.PURPOSE.DRAWING)
i3.TECH.GDSII.LAYERTABLE[(process, i3.TECH.PURPOSE.DRAWING)] = (500, 0)

# Paths with different path types
elements = i3.ElementList()
elements += i3.Path(
    layer=layer, line_width=1.0, shape=[(0.0, 0.0), (10.0, 0.0), (10.0, 10.0)], path_type=i3.PATH_TYPE.NORMAL
)

elements += i3.Path(
    layer=layer, line_width=1.0, shape=[(20.0, 0.0), (30.0, 0.0), (30.0, 10.0)], path_type=i3.PATH_TYPE.ROUNDED
)

elements += i3.Path(
    layer=layer, line_width=1.0, shape=[(40.0, 0.0), (50.0, 0.0), (50.0, 10.0)], path_type=i3.PATH_TYPE.EXTENDED
)

elements += i3.Path(
    layer=layer,
    line_width=1.0,
    shape=[(60.0, 0.0), (70.0, 0.0), (70.0, 10.0)],
    path_type=i3.PATH_TYPE.VARIABLE,
    extension=(3.0, 1.0),
)

example_path = i3.LayoutCell(name="example_path").Layout(elements=elements)
example_path.write_gdsii("example_path.gds")
example_path.visualize()  # note: visualize() doesn't show PATH_TYPE.ROUNDED
../../../../_images/ipkiss3-all-Path-1.png
set_line_width(new_line_width)

sets the line width property of the Path.

Parameters:
new_line_widthpositive number
size_info()

Returns a SizeInfo object corresponding to this element.

Returns:
SizeInfo object

See also

SizeInfo
convex_hull()

returns a Shape object describing the convex hull of this element.

Returns:
Shape object

See also

Shape
flat_copy(level=-1)

Returns a flattened copy (i.e. no more layout hierarchy) of this element.

Returns:
ElementList object
expand_transform()

Applies the built-in transform to the shape coordinates and the path width.

Returns:
This Element object.