writeGhostMatrix function
Writes translate(−origin) ∘ p into m, an identity-initialised
column-major 4×4 (canvas.transform's layout): the linear part of p in
[0] [1] [4] [5], its translation less origin in [12] [13]. Composed
in doubles; the other ten entries are left as they are.
Implementation
void writeGhostMatrix(Float64List m, Transform2 p, Vector2 origin) {
_writeLinear(m, p);
_writeTranslation(m, p, origin);
}