transform method

V3 transform(
  1. M o
)

Transforms this vector by matrix o.

Applies the full 4x4 affine transformation; the W component is implicitly treated as 1 (i.e. the translation column is applied).

Implementation

V3 transform(M o) => _v3(
  o.m0*x + o.m4*y + o.m8*z + o.m12,
  o.m1*x + o.m5*y + o.m9*z + o.m13,
  o.m2*x + o.m6*y + o.m10*z + o.m14,
);