matrix4 method

void matrix4(
  1. int offset,
  2. Matrix4 m
)

Writes a 4×4 matrix (column-major, as both the engine and GLSL store it) at offset.

Implementation

void matrix4(int offset, Matrix4 m) {
  final s = m.storage;
  for (var i = 0; i < 16; i++) {
    bytes.setFloat32(offset + i * 4, s[i], Endian.host);
  }
}