Home » U++ Library support » Draw, Display, Images, Bitmaps, Icons » How to rotate an image
Re: How to rotate an image [message #21745 is a reply to message #21744] |
Wed, 03 June 2009 14:55 |
mr_ped
Messages: 825 Registered: November 2005 Location: Czech Republic - Praha
|
Experienced Contributor |
|
|
In Draw/ImageOp.h there are:
Image RotateClockwise(const Image& img);
Image RotateAntiClockwise(const Image& img);
Image MirrorHorz(const Image& img);
Image MirrorVert(const Image& img);
Image Rotate(const Image& m, int angle);
But I can't find any documentation about it anywhere, I just use it in my own code (the RotateClockwise one) and it works, maybe it will help you too.
I can't see anything else in draw about rotating of full image or drawdraw, which doesn't make sense a little bit, when we speak about vector components like DrawingDraw, maybe some global transform matrix would be nice touch there.
But if I recall it correctly, Mirek prefer's Draw in stateless way, so setting up "view matrix" would not work, maybe some convert function: DrawingDraw TransformDrawingDraw( const DrawingDraw & w, const [transformmatrixtype] & tm ); ??
But for example Clipping operation does set state of Draw, sooo ... well. I didn't work with these things for long time, so I'm not sure what to think about it and what would be a proper way to go.
[Updated on: Wed, 03 June 2009 14:57] Report message to a moderator
|
|
|
Goto Forum:
Current Time: Wed May 08 05:18:49 CEST 2024
Total time taken to generate the page: 0.02656 seconds
|