ifcopenshell.api.boundary.assign_connection_geometry

Module Contents

class ifcopenshell.api.boundary.assign_connection_geometry.Usecase
close_polyline(points)
create_plane(location, axis, ref_direction)
create_point(point)
create_polyline(points)
execute()
ifcopenshell.api.boundary.assign_connection_geometry.assign_connection_geometry(file: ifcopenshell.file, rel_space_boundary: ifcopenshell.entity_instance, outer_boundary: list[tuple[float, float]], location: tuple[float, float, float], axis: tuple[float, float, float], ref_direction: tuple[float, float, float], inner_boundaries: list[list[tuple[float, float]]] | None = None, unit_scale: float | None = None) None

Create and assign a connection geometry to a space boundary relationship

A space boundary may optionally have a plane that represents how that space is adjacent to another space, known as the connection geometry. You may specify this plane in terms of an outer boundary polyline, zero or more inner boundaries (such as for windows), and a positional matrix for the orientation of the plane.

Parameters:
  • rel_space_boundary (ifcopenshell.entity_instance) – The space boundary relationship to assign the connection geometry to.

  • outer_boundary (list[tuple[float, float]]) – A list of 2D points representing an open polyline. The last point will connect to the first point. Each point is represented by an interable of 2 floats. The coordinates of the points are relative to the positional matrix arguments.

  • inner_boundaries (list[list[tuple[float, float]]], optional) – A list of zero or more inner boundaries to use for the plane. Each boundary is represented by an open polyline, as defined by the outer_boundary argument.

  • location (tuple[float, float, float]) – The local origin of the connection geometry, defined as an XYZ coordinate relative to the placement of the space that is being bounded.

  • axis (tuple[float, float, float]) – The local X axis of the connection geometry, defined as an XYZ vector relative to the placement of the space that is being bounded.

  • ref_direction (tuple[float, float, float]) – The local Z axis of the connection geometry, defined as an XYZ vector relative to the placement of the space that is being bounded. The Y vector is automatically derived using the right hand rule.

  • unit_scale (float, optional) – The unit scale as calculated by ifcopenshell.util.unit.calculate_unit_scale. If not provided, it will be automatically calculated for you.

Returns:

None

Return type:

None

Example:

ifcopenshell.api.boundary.assign_connection_geometry(model,
    rel_space_boundary=element,
    outer_boundary=[(0., 0.), (1., 0.), (1., 1.), (0., 1.)],
    location=[0., 0., 0.], axis=[1., 0., 0.], ref_direction=[0., 0., 1.],
    )