mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 13:06:59 -04:00
Added 'angle' property for choice fields
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@315 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -83,13 +83,10 @@ struct Rotate270 {
|
||||
// ----------------------------------------------------------------------------- : Interface
|
||||
|
||||
Image rotate_image(const Image& image, int angle) {
|
||||
if (angle == 90) {
|
||||
return rotate_image_impl<Rotate90>(image);
|
||||
} else if (angle == 180){
|
||||
return rotate_image_impl<Rotate180>(image);
|
||||
} else if (angle == 270){
|
||||
return rotate_image_impl<Rotate270>(image);
|
||||
} else{
|
||||
return image;
|
||||
switch (angle % 360) {
|
||||
case 90: return rotate_image_impl<Rotate90> (image);
|
||||
case 180: return rotate_image_impl<Rotate180>(image);
|
||||
case 270: return rotate_image_impl<Rotate270>(image);
|
||||
default: return image;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user