mirror of
https://github.com/DarthAffe/RGB.NET.git
synced 2026-11-10 20:46:24 +00:00
Improved color-calculation of novation devices
This commit is contained in:
1 parent
5440f9844f
commit
3a9d8e2e6d
9 files changed
+134
-40
No files matched your search
@@ -16,6 +16,13 @@ namespace RGB.NET.Devices.Novation
|
||||
/// <returns>The value of the <see cref="DeviceIdAttribute"/> of the source.</returns>
|
||||
internal static string GetDeviceId(this Enum source) => source.GetAttribute<DeviceIdAttribute>()?.Id;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the value of the <see cref="ColorCapabilityAttribute"/>.
|
||||
/// </summary>
|
||||
/// <param name="source">The enum value to get the description from.</param>
|
||||
/// <returns>The value of the <see cref="ColorCapabilityAttribute"/> of the source.</returns>
|
||||
internal static NovationColorCapabilities GetColorCapability(this Enum source) => source.GetAttribute<ColorCapabilityAttribute>()?.Capability ?? NovationColorCapabilities.None;
|
||||
|
||||
/// <summary>
|
||||
/// Gets the attribute of type T.
|
||||
/// </summary>
|
||||
|
||||
Reference in new issue
Block a user