ExtrusionSpec¶
- class photonforge.ExtrusionSpec(mask_spec, medium, limits, sidewall_angle=0)¶
Extrusion specification for masks.
This class is mainly used to create extrusion recipes for a
Technology
.- Parameters:
mask_spec – Mask specification for this extrusion.
medium – Tidy3D medium for the resulting structures.
limits – Out-of-plane extrusion limits.
sidewall_angle – Sidewall angle for extrusion (in degrees). Affects the bottom face of the extruded mask (reference on top). Positive (negative) values will dilate (erode) the bottom face.
Example
>>> extrusion_spec = ExtrusionSpec( ... MaskSpec((1, 0)), ... td.Medium(permittivity=3.48**2), ... limits=(0, 0.250), ... sidewall_angle=8, ... )
Methods
copy
([deep])Create a copy of this extrusion specification.
extrude
(*structures[, extrusion_tolerance])Extrude planar structures according to this extrusion specification.
from_json
(json_str)Create an extrusion specification object from a json string.
Attributes
Json representation of this extrusion specification.
Extrusion limits.
Extrusion mask specification.
Extrusion medium.
Extrusion sidewall_angle.
- copy(deep=False)¶
Create a copy of this extrusion specification.
- Parameters:
deep – If set, creates a copy of mask specification as well. Otherwise, the same mask specification object will be used.
- Returns:
New copy.
- extrude(*structures, extrusion_tolerance=0)¶
Extrude planar structures according to this extrusion specification.
- Parameters:
*structures – Structures to be extruded. Must be instances of
Rectangle
,Circle, :class:`Polygon
, orPath
.extrusion_tolerance – Minimal dimension to search for topological changes in angled extrusions or fallback to an orthogonal profile. A value of 0 or less defaults to
config.tolerance
.
- Returns:
List of polyhedra.
Note
The mask specification in this object is not taken into account. All structures are used in the extrusion and no dilation is applied.
- static from_json(json_str)¶
Create an extrusion specification object from a json string.
- Parameters:
json_str – Strig containing the json data.
- Returns:
ExtrusionSpec instance.
- json¶
Json representation of this extrusion specification.
- limits¶
Extrusion limits.
- mask_spec¶
Extrusion mask specification.
- medium¶
Extrusion medium.
- sidewall_angle¶
Extrusion sidewall_angle.