using RGB.NET.Core;
namespace RGB.NET.Devices.Asus;
///
///
/// Represents a Asus headset.
///
public sealed class AsusUnspecifiedRGBDevice : AsusRGBDevice, IUnknownDevice
{
#region Properties & Fields
private LedId _baseLedId;
#endregion
#region Constructors
///
///
/// Initializes a new instance of the class.
///
/// The specific information provided by Asus for the headset.
/// The ledId of the first led of this device. All other leds are created by incrementing this base-id by 1.
/// The update trigger used to update this device.
internal AsusUnspecifiedRGBDevice(AsusRGBDeviceInfo info, LedId baseLedId, IDeviceUpdateTrigger updateTrigger)
: base(info, updateTrigger)
{
this._baseLedId = baseLedId;
InitializeLayout();
}
#endregion
#region Methods
private void InitializeLayout()
{
int ledCount = DeviceInfo.Device.Lights.Count;
for (int i = 0; i < ledCount; i++)
AddLed(_baseLedId + i, new Point(i * 10, 0), new Size(10, 10));
}
///
protected override object? GetLedCustomData(LedId ledId) => (int)ledId - (int)_baseLedId;
#endregion
}