rotateByCenter method
Rotates by angleRadians
radians, clockwise.
The axis of rotation will be the center of the object with the given size.
Implementation
Matrix4Transform rotateByCenter(double angleRadians, Size size) => rotate(
angleRadians,
origin: Offset(size.width / 2, size.height / 2),
);