Open
Description
translation ended up giving me massively skewed projections when doing 2d transforms.
translate does:
1 0 0
0 1 0
tx ty 1
it needs to do:
1 0 tx
0 1 ty
0 0 1
function translation(tx, ty, dst) {
dst = dst || new MatType(9);
dst[0] = 1;
dst[1] = 0;
dst[2] = tx;
dst[3] = 0;
dst[4] = 1;
dst[5] = ty;
dst[6] = 0;
dst[7] = 0;
dst[8] = 1;
return dst;
}
Metadata
Assignees
Labels
No labels