Topics
All
MacOS
(Only)
Windows
(Only)
Linux
(Only, Not)
iOS
(Only, Not)
Components
Crossplatform Mac & Win
Server
Client
Old
Deprecated
Guides
Examples
Videos
New in version:
10.1
10.2
10.3
10.4
10.5
11.0
11.1
11.2
11.3
11.4
Statistic
FMM
Blog
Rotate image by specified number of degrees.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
GraphicsMagick | 2.0 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
Parameter | Description | Example |
---|---|---|
ImageRef | The image reference number. | 1 |
degrees | The angle in degrees. | 90 |
Returns "OK" on success.
Rotates image by 90 degree to right
Let (
[
$Image = MBS("GMImage.NewFromContainer"; GraphicsMagick::image);
$RotateResult = MBS("GMImage.Rotate"; $Image; 90);
$Result = MBS("GMImage.WriteToPNGContainer"; $Image);
$DestroyResult = MBS("GMImage.Release";$Image)
];
$Result)
Custom function to rotate image:
/*
MBS_Image_Rotate (Picture; rotation)
Picture: Container 'MyTable::MyField"
rotation: Grad ° - numeric Value, positiv OR negative
Benjamin Fehr, EfficientBizz GmbH
http://www.efficientbizz.com
*/
Let (
[
$Image = MBS("GMImage.NewFromContainer"; Picture);
$RotateResult = MBS("GMImage.Rotate"; $Image; rotation);
$Result = MBS("GMImage.WriteToPNGContainer"; $Image);
$DestroyResult = MBS("GMImage.Release";$Image)
];
$Result)
Created 18th August 2014, last changed 21st December 2018
GMImage.Rollxy - GMImage.Rotating
Feedback: Report problem or ask question.