fixed scaling bug

This commit is contained in:
Alexander Eckart committed 2012-04-07 17:22:29 +02:00
1 parent 85055dfd20
commit c52e82becc
2 files changed
+4 -4

No files matched your search

+2 -2
View File
@@ -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;
+2 -2
View File
@@ -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;