SkMatrix m1, m2; m1.setRotate(45.0f); m2.setScale(2.0f, 2.0f); m1.postConcat(m2);
SkMatrix m; m.setScale(2.0f, 2.0f); m.postRotate(45.0f);In this example, we create a transformation matrix that scales by 2x in both dimensions. We then apply a rotation of 45 degrees using postRotate(). Since postConcat() is used after setScale(), the rotation will be applied after scaling. Package library: Skia Graphics Library, a 2D graphics library for drawing text, shapes, and images, developed by Google.