get_elements_for_generated_layers
- ipkiss3.all.get_elements_for_generated_layers(elements, mapping)
Returns a list of elements on specified generated layers from the given layout data
Given a list of elements (or layout view or layout data container) and a dict {generatedlayer: layer}, returns new elements on the specified PPLayer according to the boolean operations of the GeneratedLayer.
- Parameters:
- elements: ElementList, LayoutData or LayoutView
List of input elements, layout data or layout view.
- mapping: dict {Layer: Layer}
Maps generated layers (keys) on output layers (values)
- Returns:
- ElementList containing the resulting elements only on the layers specified in mapping
- after layer generation (booleans).
See also
Examples
import ipkiss3.all as i3 layer0 = i3.Layer(0) layer1 = i3.Layer(1) layer2 = i3.Layer(2) twocircles = i3.LayoutCell().Layout( elements=[ i3.Circle(layer=layer0, center=(0.0, 0.0), radius=10.0), i3.Circle(layer=layer1, center=(7.5, 7.5), radius=3.0), ] ) twocircles.visualize() xor_elements = i3.get_elements_for_generated_layers( elements=twocircles, mapping={layer0 ^ layer1: layer2} ) twocircles_xor = i3.LayoutCell().Layout(elements=xor_elements) twocircles_xor.visualize()