fixed scaling bug
This commit is contained in:
1 parent
85055dfd20
commit
c52e82becc
2 files changed
+4
-4
No files matched your search
@@ -903,13 +903,13 @@ namespace Vocaluxe.Lib.Draw
|
||||
int w = bmp.Width;
|
||||
int h = bmp.Height;
|
||||
|
||||
if (h >= w && w > MaxSize)
|
||||
if (w > MaxSize)
|
||||
{
|
||||
h = (int)Math.Round((float)MaxSize / bmp.Width * bmp.Height);
|
||||
w = MaxSize;
|
||||
}
|
||||
|
||||
if (w >= h && h > MaxSize)
|
||||
if (h > MaxSize)
|
||||
{
|
||||
w = (int)Math.Round((float)MaxSize / bmp.Height * bmp.Width);
|
||||
h = MaxSize;
|
||||
|
||||
@@ -724,13 +724,13 @@ namespace Vocaluxe.Lib.Draw
|
||||
int w = bmp.Width;
|
||||
int h = bmp.Height;
|
||||
|
||||
if (h >= w && w > MaxSize)
|
||||
if (w > MaxSize)
|
||||
{
|
||||
h = (int)Math.Round((float)MaxSize / bmp.Width * bmp.Height);
|
||||
w = MaxSize;
|
||||
}
|
||||
|
||||
if (w >= h && h > MaxSize)
|
||||
if (h > MaxSize)
|
||||
{
|
||||
w = (int)Math.Round((float)MaxSize / bmp.Height * bmp.Width);
|
||||
h = MaxSize;
|
||||
|
||||
Reference in new issue
Block a user