Skip to content

Geom.piece()

Description

Creates a motor detail from geometric form and material.

Syntax

JS
Geom.piece(shp: Shape, material: ConductorMaterial|CustomMaterial|EmptyMaterial|EndturnMaterial|GeneralMaterial|IronMaterial|MagnetParallelMaterial|MagnetRadialMaterial) -> Piece

Parameters

Parameter Type Mandatory Description
shp Shape ✅ Geometric shape of the detail.
material ConductorMaterial\|CustomMaterial\|EmptyMaterial\|EndturnMaterial\|GeneralMaterial\|IronMaterial\|MagnetParallelMaterial\|MagnetRadialMaterial ✅ Material of the detail.

Return value

Type Description
Piece Object of type Piece, motor detail.

Example

JS
1
2
3
4
let shp = Geom.cylinder(100, 100)
let material = Material.general();
let piece = Geom.piece(shp, material)
console.info(piece) // output:

See also

Geom

Material

Last update: 14 August 2025, 18:47