1
0
mirror of https://github.com/Artemis-RGB/Artemis synced 2025-12-13 05:48:35 +00:00
This commit is contained in:
SpoinkyNL 2016-11-03 23:27:42 +01:00
commit 3bb15f70c3
2 changed files with 6 additions and 2 deletions

View File

@ -118,7 +118,7 @@ namespace Artemis.DeviceProviders.Corsair
}
_keyboardBrush.Image = image;
_keyboard.Update(true);
_keyboard.Update();
image.Dispose();
}

View File

@ -38,8 +38,12 @@ namespace Artemis.Profiles.Layers.Types.AmbientLight.AmbienceCreator
double widthPixels = effectiveSourceWidth / (double)targetWidth;
double heightPixels = relevantSourceHeight / (double)targetHeight;
if (widthPixels <= 0 || heightPixels <= 0 || (relevantSourceHeight + relevantOffsetTop > sourceHeight) || effectiveSourceWidth > sourceWidth)
if (widthPixels <= 0 || heightPixels <= 0 || (relevantSourceHeight + relevantOffsetTop > sourceHeight) ||
effectiveSourceWidth > sourceWidth)
{
colors = colors.ExtendHeight(targetHeight);
return colors.ToBGRArray();
}
int increment = Math.Max(1, Math.Min(20, settings.Downsampling));
for (int y = 0; y < relevantSourceHeight; y += increment)