MCPcopy Index your code
hub / github.com/CadQuery/cadquery / _get_face_lists_strict

Function _get_face_lists_strict

cadquery/occ_impl/shapes.py:5304–5326  ·  view source on GitHub ↗

Get lists of faces for sweeping. No vertices are allowed.

(s: Sequence[Shape])

Source from the content-addressed store, hash-verified

5302
5303
5304def _get_face_lists_strict(s: Sequence[Shape]) -> list[list[Face]]:
5305 """
5306 Get lists of faces for sweeping. No vertices are allowed.
5307 """
5308
5309 face_lists: list[list[Face]] = []
5310
5311 ix_last = len(s) - 1
5312
5313 for i, el in enumerate(s):
5314 if i == 0:
5315
5316 face_lists = [[f] for f in el.Faces()]
5317
5318 # if no faces were detected return an empty list
5319 if not face_lists:
5320 break
5321
5322 else:
5323 for face_list, f in zip(face_lists, el.Faces()):
5324 face_list.append(f)
5325
5326 return face_lists
5327
5328
5329def _normalize(s: Shape) -> Shape:

Callers 1

sweepFunction · 0.85

Calls 2

appendMethod · 0.80
FacesMethod · 0.45

Tested by

no test coverage detected