Lazarus
Programming => Graphics => Graphics and Multimedia => BGRABitmap and LazPaint => Topic started by: Roland57 on April 21, 2020, 08:25:28 pm
-
Hello!
I am thinking of doing for BGRABitmap something like Cairo context. But before I go, I would to be sure that it doesn't already exists.
Cairo context is like global variables, including not only simple things like current color or current pen width, but also a coordinate system, that you can change (translate, scale, rotate), save and restore. I hope that what I say is understandable.
I attach some examples that show the principle.
Is there something like that in BGRABitmap?
-
Hi!
You are on the right road:
BGRAbitmap defines a 2D-Canvas, with which you can scale or rotate your graphic objects.
It is decribed in Chapter 14 in the tutorial:
https://wiki.freepascal.org/BGRABitmap_tutorial_14/de (https://wiki.freepascal.org/BGRABitmap_tutorial_14/de)
Happy transformations!
Winni
-
@winni
Thank you for your suggestion and for the link. Indeed, I never used Canvas2D. I will try.
Regards.
Roland