translate static method

Mat2D translate(
  1. Mat2D o,
  2. Mat2D a,
  3. Vec2D b
)

Implementation

static Mat2D translate(Mat2D o, Mat2D a, Vec2D b) {
  o[0] = a[0];
  o[1] = a[1];
  o[2] = a[2];
  o[3] = a[3];
  o[4] = a[4] + b.x;
  o[5] = a[5] + b.y;
  return o;
}