O'Reilly logo

Graphics Programming with GDI+ by Mahesh Chand

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

4.4. Transformation with Brushes

The TextureBrush, LinearGradientBrush, and PathGradientBrush classes also provide transformation methods. Brush transformation is not used very often, but it may be useful in some cases, as the following example will show.

A transformation on a TextureBrush object is a transformation of the image used as the texture. TextureBrush provides the methods MultiplyTransform, ResetTransform, RotateTransform, ScaleTransform, and TranslateTransform (see Table 4.15).

The TextureBrush class also provides a Transform property, which can be used to apply a transformation on a texture brush.

Table 4.15. TextureBrush methods
MethodDescription
MultiplyTransformMultiplies the Matrix object that represents the local geometric transformation ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required