pub fn transformed(
model: &mut Model,
shape: &Shape,
transform: Transform,
) -> OgeomResult<Built>Expand description
Move a shape by a rigid motion, sharing everything.
Cheap and exact: the result names the same topology nodes and the same geometry, at a new placement.
There is no way to pass something that is not a placement. Transform
is a similarity by construction (rigid motion with a uniform scale), and a
shear or a non-uniform scale is a
GeneralTransform, which this does not accept.
That is deliberate: such a transform carries a circle to an ellipse, and
recording it as a placement would leave every circle in the shape claiming
to be a circle while sitting on an ellipse. The type refuses it, so no
runtime check has to.
ยงErrors
OgeomError::Dangling if the shape does not
resolve in this model.