diff --git a/RGB.NET.Devices.SteelSeries/Generic/SteelSeriesDeviceUpdateQueue.cs b/RGB.NET.Devices.SteelSeries/Generic/SteelSeriesDeviceUpdateQueue.cs index 0c264df..9b43d5c 100644 --- a/RGB.NET.Devices.SteelSeries/Generic/SteelSeriesDeviceUpdateQueue.cs +++ b/RGB.NET.Devices.SteelSeries/Generic/SteelSeriesDeviceUpdateQueue.cs @@ -2,6 +2,7 @@ using System.Linq; using RGB.NET.Core; using RGB.NET.Devices.SteelSeries.API; +using RGB.NET.Devices.SteelSeries.Helper; namespace RGB.NET.Devices.SteelSeries { @@ -37,7 +38,7 @@ namespace RGB.NET.Devices.SteelSeries /// protected override void Update(Dictionary dataSet) { - SteelSeriesSDK.UpdateLeds(_deviceType, dataSet.ToDictionary(x => ((SteelSeriesLedId)x.Key).GetAPIName(), x => new int[] { x.Value.R, x.Value.G, x.Value.B })); + SteelSeriesSDK.UpdateLeds(_deviceType, dataSet.ToDictionary(x => ((SteelSeriesLedId)x.Key).GetAPIName(), x => x.Value.ToIntArray())); } #endregion diff --git a/RGB.NET.Devices.SteelSeries/Helper/ColorExtensions.cs b/RGB.NET.Devices.SteelSeries/Helper/ColorExtensions.cs new file mode 100644 index 0000000..793dc02 --- /dev/null +++ b/RGB.NET.Devices.SteelSeries/Helper/ColorExtensions.cs @@ -0,0 +1,9 @@ +using RGB.NET.Core; + +namespace RGB.NET.Devices.SteelSeries.Helper +{ + internal static class ColorExtensions + { + internal static int[] ToIntArray(this Color color) => new int[] { color.GetR(), color.GetB(), color.GetG() }; + } +}