MCPcopy
hub / github.com/CadQuery/cadquery / makeBox

Method makeBox

cadquery/occ_impl/shapes.py:4192–4208  ·  view source on GitHub ↗

makeBox(length,width,height,[pnt,dir]) -- Make a box located in pnt with the dimensions (length,width,height) By default pnt=Vector(0,0,0) and dir=Vector(0,0,1)

(
        cls,
        length: float,
        width: float,
        height: float,
        pnt: VectorLike = Vector(0, 0, 0),
        dir: VectorLike = Vector(0, 0, 1),
    )

Source from the content-addressed store, hash-verified

4190
4191 @classmethod
4192 def makeBox(
4193 cls,
4194 length: float,
4195 width: float,
4196 height: float,
4197 pnt: VectorLike = Vector(0, 0, 0),
4198 dir: VectorLike = Vector(0, 0, 1),
4199 ) -> Solid:
4200 """
4201 makeBox(length,width,height,[pnt,dir]) -- Make a box located in pnt with the dimensions (length,width,height)
4202 By default pnt=Vector(0,0,0) and dir=Vector(0,0,1)
4203 """
4204 return cls(
4205 BRepPrimAPI_MakeBox(
4206 gp_Ax2(Vector(pnt).toPnt(), Vector(dir).toDir()), length, width, height
4207 ).Shape()
4208 )
4209
4210 @classmethod
4211 def makeCone(

Callers 8

boxMethod · 0.80
makeCubeFunction · 0.80
testPlaneMethodsMethod · 0.80
makeCubesMethod · 0.80
testLocatedMovedMethod · 0.80
simple_assyFunction · 0.80
metadata_assyFunction · 0.80
test_constraint_getPlnFunction · 0.80

Calls 3

VectorClass · 0.85
toPntMethod · 0.80
toDirMethod · 0.80

Tested by 6

testPlaneMethodsMethod · 0.64
makeCubesMethod · 0.64
testLocatedMovedMethod · 0.64
simple_assyFunction · 0.64
metadata_assyFunction · 0.64
test_constraint_getPlnFunction · 0.64