Re: New coordinates after rotation and translation
No, not without trig and matrix multiplication. But you can always make a module that represents the translations and rotations and apply it to multiple children(). For example to place screws in a bracket that itself has a complicated position.
On Mon, 7 Jan 2019 at 17:43, Maurice van Peursem <[hidden email]> wrote:
Is there an easy way to get the new coordinates of a point after a
few rotations and translations?
Capsule summary: Every transformation is equivalent to a
particular 4x4 matrix. Multiplying the point by the
transformation matrix yields the transformed point. Multiplying
several transformation matrices together yields a transformation
matrix that represents all of the transformations. OpenSCAD does
matrix multiplication natively; you can just say "p*tm" where p is
a point as an [x,y,z] vector and tm is a transformation matrix,
and OpenSCAD will do the right thing and yield a new point.