1
0
mirror of https://github.com/DarthAffe/RGB.NET.git synced 2025-12-13 01:58:30 +00:00

Renamed asus SDK-integration from aura to asus for naming consistency

This commit is contained in:
Darth Affe 2017-11-11 22:01:22 +01:00
parent 22617845b0
commit 4f48c63ae2
35 changed files with 261 additions and 261 deletions

View File

@ -1,17 +1,17 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd"> <package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
<metadata> <metadata>
<id>RGB.NET.Devices.Aura</id> <id>RGB.NET.Devices.Asus</id>
<title>RGB.NET.Devices.Aura</title> <title>RGB.NET.Devices.Asus</title>
<version>1.0.0.0</version> <version>1.0.0.0</version>
<authors>Darth Affe</authors> <authors>Darth Affe</authors>
<owners>Darth Affe</owners> <owners>Darth Affe</owners>
<projectUrl>https://github.com/DarthAffe/RGB.NET</projectUrl> <projectUrl>https://github.com/DarthAffe/RGB.NET</projectUrl>
<licenseUrl>https://raw.githubusercontent.com/DarthAffe/RGB.NET/master/LICENSE</licenseUrl> <licenseUrl>https://raw.githubusercontent.com/DarthAffe/RGB.NET/master/LICENSE</licenseUrl>
<requireLicenseAcceptance>true</requireLicenseAcceptance> <requireLicenseAcceptance>true</requireLicenseAcceptance>
<description>Aura-Device-Implementations of RGB.NET</description> <description>Asus-Device-Implementations of RGB.NET</description>
<releaseNotes></releaseNotes> <releaseNotes></releaseNotes>
<summary>Aura-Device-Implementations of RGB.NET, a C# (.NET) library for accessing various RGB-peripherals</summary> <summary>Asus-Device-Implementations of RGB.NET, a C# (.NET) library for accessing various RGB-peripherals</summary>
<copyright>Copyright © Wyrez 2017</copyright> <copyright>Copyright © Wyrez 2017</copyright>
<language>en-US</language> <language>en-US</language>
<dependencies> <dependencies>
@ -20,13 +20,13 @@
</dependencies> </dependencies>
</metadata> </metadata>
<files> <files>
<file src="..\bin\RGB.NET.Devices.Aura.dll" target="lib\net45\RGB.NET.Devices.Aura.dll" /> <file src="..\bin\RGB.NET.Devices.Asus.dll" target="lib\net45\RGB.NET.Devices.Asus.dll" />
<file src="..\bin\RGB.NET.Devices.Aura.pdb" target="lib\net45\RGB.NET.Devices.Aura.pdb" /> <file src="..\bin\RGB.NET.Devices.Asus.pdb" target="lib\net45\RGB.NET.Devices.Asus.pdb" />
<file src="..\bin\RGB.NET.Devices.Aura.xml" target="lib\net45\RGB.NET.Devices.Aura.xml" /> <file src="..\bin\RGB.NET.Devices.Asus.xml" target="lib\net45\RGB.NET.Devices.Asus.xml" />
<file src="..\RGB.NET.Devices.Aura\**\*.cs" target="src" exclude="..\RGB.NET.Devices.Aura\obj\**\*.*" /> <file src="..\RGB.NET.Devices.Asus\**\*.cs" target="src" exclude="..\RGB.NET.Devices.Asus\obj\**\*.*" />
<file src="..\RGB.NET.Devices.Aura\Images\**\*.*" target="build\net45\resources\Images\" /> <file src="..\RGB.NET.Devices.Asus\Images\**\*.*" target="build\net45\resources\Images\" />
<file src="..\RGB.NET.Devices.Aura\Layouts\**\*.*" target="build\net45\resources\Layouts\" /> <file src="..\RGB.NET.Devices.Asus\Layouts\**\*.*" target="build\net45\resources\Layouts\" />
<file src="..\RGB.NET.Devices.Aura\libs\**\*.*" target="build\net45\libs\" /> <file src="..\RGB.NET.Devices.Asus\libs\**\*.*" target="build\net45\libs\" />
<file src="..\RGB.NET.Devices.Aura\targets\*.targets" target="build\net45\" /> <file src="..\RGB.NET.Devices.Asus\targets\*.targets" target="build\net45\" />
</files> </files>
</package> </package>

View File

@ -7,23 +7,23 @@ using System.Collections.ObjectModel;
using System.Globalization; using System.Globalization;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using RGB.NET.Core; using RGB.NET.Core;
using RGB.NET.Devices.Aura.Native; using RGB.NET.Devices.Asus.Native;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a device provider responsible for Cooler Master devices. /// Represents a device provider responsible for Cooler Master devices.
/// </summary> /// </summary>
public class AuraDeviceProvider : IRGBDeviceProvider public class AsusDeviceProvider : IRGBDeviceProvider
{ {
#region Properties & Fields #region Properties & Fields
private static AuraDeviceProvider _instance; private static AsusDeviceProvider _instance;
/// <summary> /// <summary>
/// Gets the singleton <see cref="AuraDeviceProvider"/> instance. /// Gets the singleton <see cref="AsusDeviceProvider"/> instance.
/// </summary> /// </summary>
public static AuraDeviceProvider Instance => _instance ?? new AuraDeviceProvider(); public static AsusDeviceProvider Instance => _instance ?? new AsusDeviceProvider();
/// <summary> /// <summary>
/// Gets a modifiable list of paths used to find the native SDK-dlls for x86 applications. /// Gets a modifiable list of paths used to find the native SDK-dlls for x86 applications.
@ -46,7 +46,7 @@ namespace RGB.NET.Devices.Aura
/// <summary> /// <summary>
/// Gets the loaded architecture (x64/x86). /// Gets the loaded architecture (x64/x86).
/// </summary> /// </summary>
public string LoadedArchitecture => _AuraSDK.LoadedArchitecture; public string LoadedArchitecture => _AsusSDK.LoadedArchitecture;
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
@ -67,12 +67,12 @@ namespace RGB.NET.Devices.Aura
#region Constructors #region Constructors
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="AuraDeviceProvider"/> class. /// Initializes a new instance of the <see cref="AsusDeviceProvider"/> class.
/// </summary> /// </summary>
/// <exception cref="InvalidOperationException">Thrown if this constructor is called even if there is already an instance of this class.</exception> /// <exception cref="InvalidOperationException">Thrown if this constructor is called even if there is already an instance of this class.</exception>
public AuraDeviceProvider() public AsusDeviceProvider()
{ {
if (_instance != null) throw new InvalidOperationException($"There can be only one instanc of type {nameof(AuraDeviceProvider)}"); if (_instance != null) throw new InvalidOperationException($"There can be only one instanc of type {nameof(AsusDeviceProvider)}");
_instance = this; _instance = this;
} }
@ -87,24 +87,24 @@ namespace RGB.NET.Devices.Aura
try try
{ {
_AuraSDK.Reload(); _AsusSDK.Reload();
IList<IRGBDevice> devices = new List<IRGBDevice>(); IList<IRGBDevice> devices = new List<IRGBDevice>();
#region Mainboard #region Mainboard
//TODO DarthAffe 21.10.2017: Requesting mainboards seems to fail if only a non mb-device (tested with only a gpu) is connected //TODO DarthAffe 21.10.2017: Requesting mainboards seems to fail if only a non mb-device (tested with only a gpu) is connected
int mainboardCount = _AuraSDK.EnumerateMbController(IntPtr.Zero, 0); int mainboardCount = _AsusSDK.EnumerateMbController(IntPtr.Zero, 0);
if (mainboardCount > 0) if (mainboardCount > 0)
{ {
IntPtr mainboardHandles = Marshal.AllocHGlobal(mainboardCount * IntPtr.Size); IntPtr mainboardHandles = Marshal.AllocHGlobal(mainboardCount * IntPtr.Size);
_AuraSDK.EnumerateMbController(mainboardHandles, mainboardCount); _AsusSDK.EnumerateMbController(mainboardHandles, mainboardCount);
for (int i = 0; i < mainboardCount; i++) for (int i = 0; i < mainboardCount; i++)
{ {
IntPtr handle = Marshal.ReadIntPtr(mainboardHandles, i); IntPtr handle = Marshal.ReadIntPtr(mainboardHandles, i);
_AuraSDK.SetMbMode(handle, 1); _AsusSDK.SetMbMode(handle, 1);
AuraMainboardRGBDevice device = new AuraMainboardRGBDevice(new AuraMainboardRGBDeviceInfo(RGBDeviceType.Mainboard, handle)); AsusMainboardRGBDevice device = new AsusMainboardRGBDevice(new AsusMainboardRGBDeviceInfo(RGBDeviceType.Mainboard, handle));
device.Initialize(); device.Initialize();
devices.Add(device); devices.Add(device);
} }
@ -114,18 +114,18 @@ namespace RGB.NET.Devices.Aura
#region Graphics cards #region Graphics cards
//TODO DarthAffe 21.10.2017: This somehow returns non-existant gpus (at least for me) which cause huge lags (if a real aura-ready gpu is connected this doesn't happen) //TODO DarthAffe 21.10.2017: This somehow returns non-existant gpus (at least for me) which cause huge lags (if a real asus-ready gpu is connected this doesn't happen)
int graphicCardCount = _AuraSDK.EnumerateGPU(IntPtr.Zero, 0); int graphicCardCount = _AsusSDK.EnumerateGPU(IntPtr.Zero, 0);
if (graphicCardCount > 0) if (graphicCardCount > 0)
{ {
IntPtr grapicsCardHandles = Marshal.AllocHGlobal(graphicCardCount * IntPtr.Size); IntPtr grapicsCardHandles = Marshal.AllocHGlobal(graphicCardCount * IntPtr.Size);
_AuraSDK.EnumerateGPU(grapicsCardHandles, graphicCardCount); _AsusSDK.EnumerateGPU(grapicsCardHandles, graphicCardCount);
for (int i = 0; i < graphicCardCount; i++) for (int i = 0; i < graphicCardCount; i++)
{ {
IntPtr handle = Marshal.ReadIntPtr(grapicsCardHandles, i); IntPtr handle = Marshal.ReadIntPtr(grapicsCardHandles, i);
_AuraSDK.SetGPUMode(handle, 1); _AsusSDK.SetGPUMode(handle, 1);
AuraGraphicsCardRGBDevice device = new AuraGraphicsCardRGBDevice(new AuraGraphicsCardRGBDeviceInfo(RGBDeviceType.GraphicsCard, handle)); AsusGraphicsCardRGBDevice device = new AsusGraphicsCardRGBDevice(new AsusGraphicsCardRGBDeviceInfo(RGBDeviceType.GraphicsCard, handle));
device.Initialize(); device.Initialize();
devices.Add(device); devices.Add(device);
} }
@ -136,17 +136,17 @@ namespace RGB.NET.Devices.Aura
#region DRAM #region DRAM
//TODO DarthAffe 29.10.2017: I don't know why they are even documented, but the asus guy said they aren't in the SDK right now. //TODO DarthAffe 29.10.2017: I don't know why they are even documented, but the asus guy said they aren't in the SDK right now.
//int dramCount = _AuraSDK.EnumerateDram(IntPtr.Zero, 0); //int dramCount = _AsusSDK.EnumerateDram(IntPtr.Zero, 0);
//if (dramCount > 0) //if (dramCount > 0)
//{ //{
// IntPtr dramHandles = Marshal.AllocHGlobal(dramCount * IntPtr.Size); // IntPtr dramHandles = Marshal.AllocHGlobal(dramCount * IntPtr.Size);
// _AuraSDK.EnumerateDram(dramHandles, dramCount); // _AsusSDK.EnumerateDram(dramHandles, dramCount);
// for (int i = 0; i < dramCount; i++) // for (int i = 0; i < dramCount; i++)
// { // {
// IntPtr handle = Marshal.ReadIntPtr(dramHandles, i); // IntPtr handle = Marshal.ReadIntPtr(dramHandles, i);
// _AuraSDK.SetDramMode(handle, 1); // _AsusSDK.SetDramMode(handle, 1);
// AuraDramRGBDevice device = new AuraDramRGBDevice(new AuraDramRGBDeviceInfo(RGBDeviceType.DRAM, handle)); // AsusDramRGBDevice device = new AsusDramRGBDevice(new AsusDramRGBDeviceInfo(RGBDeviceType.DRAM, handle));
// device.Initialize(); // device.Initialize();
// devices.Add(device); // devices.Add(device);
// } // }
@ -157,10 +157,10 @@ namespace RGB.NET.Devices.Aura
#region Keyboard #region Keyboard
IntPtr keyboardHandle = Marshal.AllocHGlobal(IntPtr.Size); IntPtr keyboardHandle = Marshal.AllocHGlobal(IntPtr.Size);
if (_AuraSDK.CreateClaymoreKeyboard(keyboardHandle)) if (_AsusSDK.CreateClaymoreKeyboard(keyboardHandle))
{ {
_AuraSDK.SetClaymoreKeyboardMode(keyboardHandle, 1); _AsusSDK.SetClaymoreKeyboardMode(keyboardHandle, 1);
AuraKeyboardRGBDevice device = new AuraKeyboardRGBDevice(new AuraKeyboardRGBDeviceInfo(RGBDeviceType.Keyboard, keyboardHandle, GetCulture())); AsusKeyboardRGBDevice device = new AsusKeyboardRGBDevice(new AsusKeyboardRGBDeviceInfo(RGBDeviceType.Keyboard, keyboardHandle, GetCulture()));
device.Initialize(); device.Initialize();
devices.Add(device); devices.Add(device);
} }
@ -170,10 +170,10 @@ namespace RGB.NET.Devices.Aura
#region Mouse #region Mouse
IntPtr mouseHandle = Marshal.AllocHGlobal(IntPtr.Size); IntPtr mouseHandle = Marshal.AllocHGlobal(IntPtr.Size);
if (_AuraSDK.CreateRogMouse(mouseHandle)) if (_AsusSDK.CreateRogMouse(mouseHandle))
{ {
_AuraSDK.SetRogMouseMode(mouseHandle, 1); _AsusSDK.SetRogMouseMode(mouseHandle, 1);
AuraMouseRGBDevice device = new AuraMouseRGBDevice(new AuraMouseRGBDeviceInfo(RGBDeviceType.Mouse, mouseHandle)); AsusMouseRGBDevice device = new AsusMouseRGBDevice(new AsusMouseRGBDeviceInfo(RGBDeviceType.Mouse, mouseHandle));
device.Initialize(); device.Initialize();
devices.Add(device); devices.Add(device);
} }
@ -200,17 +200,17 @@ namespace RGB.NET.Devices.Aura
{ {
foreach (IRGBDevice device in Devices) foreach (IRGBDevice device in Devices)
{ {
AuraRGBDeviceInfo deviceInfo = (AuraRGBDeviceInfo)device.DeviceInfo; AsusRGBDeviceInfo deviceInfo = (AsusRGBDeviceInfo)device.DeviceInfo;
switch (deviceInfo.DeviceType) switch (deviceInfo.DeviceType)
{ {
case RGBDeviceType.Mainboard: case RGBDeviceType.Mainboard:
_AuraSDK.SetMbMode(deviceInfo.Handle, 0); _AsusSDK.SetMbMode(deviceInfo.Handle, 0);
break; break;
case RGBDeviceType.GraphicsCard: case RGBDeviceType.GraphicsCard:
_AuraSDK.SetGPUMode(deviceInfo.Handle, 0); _AsusSDK.SetGPUMode(deviceInfo.Handle, 0);
break; break;
//case RGBDeviceType.DRAM: //case RGBDeviceType.DRAM:
// _AuraSDK.SetDramMode(deviceInfo.Handle, 0); // _AsusSDK.SetDramMode(deviceInfo.Handle, 0);
// break; // break;
} }
} }

View File

@ -1,20 +1,20 @@
//using RGB.NET.Core; //using RGB.NET.Core;
//using RGB.NET.Devices.Aura.Native; //using RGB.NET.Devices.Asus.Native;
//namespace RGB.NET.Devices.Aura //namespace RGB.NET.Devices.Asus
//{ //{
// /// <inheritdoc /> // /// <inheritdoc />
// /// <summary> // /// <summary>
// /// Represents a Aura dram. // /// Represents a Asus dram.
// /// </summary> // /// </summary>
// public class AuraDramRGBDevice : AuraRGBDevice // public class AsusDramRGBDevice : AsusRGBDevice
// { // {
// #region Properties & Fields // #region Properties & Fields
// /// <summary> // /// <summary>
// /// Gets information about the <see cref="AuraDramRGBDevice"/>. // /// Gets information about the <see cref="AsusDramRGBDevice"/>.
// /// </summary> // /// </summary>
// public AuraDramRGBDeviceInfo DramDeviceInfo { get; } // public AsusDramRGBDeviceInfo DramDeviceInfo { get; }
// #endregion // #endregion
@ -22,10 +22,10 @@
// /// <inheritdoc /> // /// <inheritdoc />
// /// <summary> // /// <summary>
// /// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Aura.AuraDramRGBDevice" /> class. // /// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Asus.AsusDramRGBDevice" /> class.
// /// </summary> // /// </summary>
// /// <param name="info">The specific information provided by Aura for the DRAM.</param> // /// <param name="info">The specific information provided by Asus for the DRAM.</param>
// internal AuraDramRGBDevice(AuraDramRGBDeviceInfo info) // internal AsusDramRGBDevice(AsusDramRGBDeviceInfo info)
// : base(info) // : base(info)
// { // {
// this.DramDeviceInfo = info; // this.DramDeviceInfo = info;
@ -39,17 +39,17 @@
// protected override void InitializeLayout() // protected override void InitializeLayout()
// { // {
// //TODO DarthAffe 21.10.2017: Look for a good default layout // //TODO DarthAffe 21.10.2017: Look for a good default layout
// int ledCount = _AuraSDK.GetGPULedCount(DramDeviceInfo.Handle); // int ledCount = _AsusSDK.GetGPULedCount(DramDeviceInfo.Handle);
// for (int i = 0; i < ledCount; i++) // for (int i = 0; i < ledCount; i++)
// InitializeLed(new AuraLedId(this, AuraLedIds.DramLed1 + i, i), new Rectangle(i * 10, 0, 10, 10)); // InitializeLed(new AsusLedId(this, AsusLedIds.DramLed1 + i, i), new Rectangle(i * 10, 0, 10, 10));
// //TODO DarthAffe 21.10.2017: We don't know the model, how to save layouts and images? // //TODO DarthAffe 21.10.2017: We don't know the model, how to save layouts and images?
// ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Aura\Drams\{DramDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"), // ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Asus\Drams\{DramDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"),
// null, PathHelper.GetAbsolutePath(@"Images\Aura\Drams")); // null, PathHelper.GetAbsolutePath(@"Images\Asus\Drams"));
// } // }
// /// <inheritdoc /> // /// <inheritdoc />
// protected override void ApplyColorData() => _AuraSDK.SetDramColor(DramDeviceInfo.Handle, ColorData); // protected override void ApplyColorData() => _AsusSDK.SetDramColor(DramDeviceInfo.Handle, ColorData);
// #endregion // #endregion
// } // }

View File

@ -1,26 +1,26 @@
using System; using System;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic information for a <see cref="T:RGB.NET.Devices.Aura.AuraDramRGBDevice" />. /// Represents a generic information for a <see cref="T:RGB.NET.Devices.Asus.AsusDramRGBDevice" />.
/// </summary> /// </summary>
public class AuraDramRGBDeviceInfo : AuraRGBDeviceInfo public class AsusDramRGBDeviceInfo : AsusRGBDeviceInfo
{ {
#region Constructors #region Constructors
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Internal constructor of managed <see cref="T:RGB.NET.Devices.Aura.AuraDramRGBDeviceInfo" />. /// Internal constructor of managed <see cref="T:RGB.NET.Devices.Asus.AsusDramRGBDeviceInfo" />.
/// </summary> /// </summary>
/// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param> /// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param>
/// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param> /// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param>
internal AuraDramRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle) internal AsusDramRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle)
: base(deviceType, handle) : base(deviceType, handle)
{ {
Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Aura\Drams\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute); Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Asus\Drams\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute);
} }
#endregion #endregion

View File

@ -2,12 +2,12 @@
#pragma warning disable 1591 // Missing XML comment for publicly visible type or member #pragma warning disable 1591 // Missing XML comment for publicly visible type or member
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <summary> /// <summary>
/// Contains list of all LEDs available for all Aura devices. /// Contains list of all LEDs available for all Asus devices.
/// </summary> /// </summary>
public enum AuraLedIds public enum AsusLedIds
{ {
Invalid = -1, Invalid = -1,

View File

@ -3,12 +3,12 @@
#pragma warning disable 1591 // Missing XML comment for publicly visible type or member #pragma warning disable 1591 // Missing XML comment for publicly visible type or member
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <summary> /// <summary>
/// Contains list of available logical layouts for aura keyboards. /// Contains list of available logical layouts for asus keyboards.
/// </summary> /// </summary>
public enum AuraLogicalKeyboardLayout public enum AsusLogicalKeyboardLayout
{ {
TODO TODO
}; };

View File

@ -1,12 +1,12 @@
// ReSharper disable UnusedMember.Global // ReSharper disable UnusedMember.Global
// ReSharper disable InconsistentNaming // ReSharper disable InconsistentNaming
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <summary> /// <summary>
/// Contains list of available physical layouts for aura keyboards. /// Contains list of available physical layouts for asus keyboards.
/// </summary> /// </summary>
public enum AuraPhysicalKeyboardLayout public enum AsusPhysicalKeyboardLayout
{ {
TODO TODO
} }

View File

@ -1,18 +1,18 @@
using System.Diagnostics; using System.Diagnostics;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a Id of a <see cref="T:RGB.NET.Core.Led" /> on a <see cref="T:RGB.NET.Devices.Aura.AuraRGBDevice" />. /// Represents a Id of a <see cref="T:RGB.NET.Core.Led" /> on a <see cref="T:RGB.NET.Devices.Asus.AsusRGBDevice" />.
/// </summary> /// </summary>
[DebuggerDisplay("{" + nameof(LedId) + "}")] [DebuggerDisplay("{" + nameof(LedId) + "}")]
public class AuraLedId : ILedId public class AsusLedId : ILedId
{ {
#region Properties & Fields #region Properties & Fields
internal readonly AuraLedIds LedId; internal readonly AsusLedIds LedId;
internal readonly int Index; internal readonly int Index;
@ -20,30 +20,30 @@ namespace RGB.NET.Devices.Aura
public IRGBDevice Device { get; } public IRGBDevice Device { get; }
/// <inheritdoc /> /// <inheritdoc />
public bool IsValid => LedId != AuraLedIds.Invalid; public bool IsValid => LedId != AsusLedIds.Invalid;
#endregion #endregion
#region Constructors #region Constructors
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="AuraLedId"/> class. /// Initializes a new instance of the <see cref="AsusLedId"/> class.
/// </summary> /// </summary>
/// <param name="device">The <see cref="IRGBDevice"/> the <see cref="ILedId"/> belongs to.</param> /// <param name="device">The <see cref="IRGBDevice"/> the <see cref="ILedId"/> belongs to.</param>
/// <param name="ledId">The <see cref="AuraLedId"/> of the represented <see cref="Led"/>.</param> /// <param name="ledId">The <see cref="AsusLedId"/> of the represented <see cref="Led"/>.</param>
public AuraLedId(IRGBDevice device, AuraLedIds ledId) public AsusLedId(IRGBDevice device, AsusLedIds ledId)
{ {
this.Device = device; this.Device = device;
this.LedId = ledId; this.LedId = ledId;
} }
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="AuraLedId"/> class. /// Initializes a new instance of the <see cref="AsusLedId"/> class.
/// </summary> /// </summary>
/// <param name="device">The <see cref="IRGBDevice"/> the <see cref="ILedId"/> belongs to.</param> /// <param name="device">The <see cref="IRGBDevice"/> the <see cref="ILedId"/> belongs to.</param>
/// <param name="ledId">The <see cref="AuraLedId"/> of the represented <see cref="Led"/>.</param> /// <param name="ledId">The <see cref="AsusLedId"/> of the represented <see cref="Led"/>.</param>
/// <param name="index">The index in the mapping array of the device.</param> /// <param name="index">The index in the mapping array of the device.</param>
public AuraLedId(IRGBDevice device, AuraLedIds ledId, int index) public AsusLedId(IRGBDevice device, AsusLedIds ledId, int index)
{ {
this.Device = device; this.Device = device;
this.LedId = ledId; this.LedId = ledId;
@ -55,19 +55,19 @@ namespace RGB.NET.Devices.Aura
#region Methods #region Methods
/// <summary> /// <summary>
/// Converts the Id of this <see cref="AuraLedId"/> to a human-readable string. /// Converts the Id of this <see cref="AsusLedId"/> to a human-readable string.
/// </summary> /// </summary>
/// <returns>A string that contains the Id of this <see cref="AuraLedId"/>. For example "Enter".</returns> /// <returns>A string that contains the Id of this <see cref="AsusLedId"/>. For example "Enter".</returns>
public override string ToString() => LedId.ToString(); public override string ToString() => LedId.ToString();
/// <summary> /// <summary>
/// Tests whether the specified object is a <see cref="AuraLedId" /> and is equivalent to this <see cref="AuraLedId" />. /// Tests whether the specified object is a <see cref="AsusLedId" /> and is equivalent to this <see cref="AsusLedId" />.
/// </summary> /// </summary>
/// <param name="obj">The object to test.</param> /// <param name="obj">The object to test.</param>
/// <returns><c>true</c> if <paramref name="obj" /> is a <see cref="AuraLedId" /> equivalent to this <see cref="AuraLedId" />; otherwise, <c>false</c>.</returns> /// <returns><c>true</c> if <paramref name="obj" /> is a <see cref="AsusLedId" /> equivalent to this <see cref="AsusLedId" />; otherwise, <c>false</c>.</returns>
public override bool Equals(object obj) public override bool Equals(object obj)
{ {
AuraLedId compareLedId = obj as AuraLedId; AsusLedId compareLedId = obj as AsusLedId;
if (ReferenceEquals(compareLedId, null)) if (ReferenceEquals(compareLedId, null))
return false; return false;
@ -81,9 +81,9 @@ namespace RGB.NET.Devices.Aura
} }
/// <summary> /// <summary>
/// Returns a hash code for this <see cref="AuraLedId" />. /// Returns a hash code for this <see cref="AsusLedId" />.
/// </summary> /// </summary>
/// <returns>An integer value that specifies the hash code for this <see cref="AuraLedId" />.</returns> /// <returns>An integer value that specifies the hash code for this <see cref="AsusLedId" />.</returns>
public override int GetHashCode() => LedId.GetHashCode(); public override int GetHashCode() => LedId.GetHashCode();
#endregion #endregion
@ -91,20 +91,20 @@ namespace RGB.NET.Devices.Aura
#region Operators #region Operators
/// <summary> /// <summary>
/// Returns a value that indicates whether two specified <see cref="AuraLedId" /> are equal. /// Returns a value that indicates whether two specified <see cref="AsusLedId" /> are equal.
/// </summary> /// </summary>
/// <param name="ledId1">The first <see cref="AuraLedId" /> to compare.</param> /// <param name="ledId1">The first <see cref="AsusLedId" /> to compare.</param>
/// <param name="ledId2">The second <see cref="AuraLedId" /> to compare.</param> /// <param name="ledId2">The second <see cref="AsusLedId" /> to compare.</param>
/// <returns><c>true</c> if <paramref name="ledId1" /> and <paramref name="ledId2" /> are equal; otherwise, <c>false</c>.</returns> /// <returns><c>true</c> if <paramref name="ledId1" /> and <paramref name="ledId2" /> are equal; otherwise, <c>false</c>.</returns>
public static bool operator ==(AuraLedId ledId1, AuraLedId ledId2) => ReferenceEquals(ledId1, null) ? ReferenceEquals(ledId2, null) : ledId1.Equals(ledId2); public static bool operator ==(AsusLedId ledId1, AsusLedId ledId2) => ReferenceEquals(ledId1, null) ? ReferenceEquals(ledId2, null) : ledId1.Equals(ledId2);
/// <summary> /// <summary>
/// Returns a value that indicates whether two specified <see cref="AuraLedId" /> are equal. /// Returns a value that indicates whether two specified <see cref="AsusLedId" /> are equal.
/// </summary> /// </summary>
/// <param name="ledId1">The first <see cref="AuraLedId" /> to compare.</param> /// <param name="ledId1">The first <see cref="AsusLedId" /> to compare.</param>
/// <param name="ledId2">The second <see cref="AuraLedId" /> to compare.</param> /// <param name="ledId2">The second <see cref="AsusLedId" /> to compare.</param>
/// <returns><c>true</c> if <paramref name="ledId1" /> and <paramref name="ledId2" /> are not equal; otherwise, <c>false</c>.</returns> /// <returns><c>true</c> if <paramref name="ledId1" /> and <paramref name="ledId2" /> are not equal; otherwise, <c>false</c>.</returns>
public static bool operator !=(AuraLedId ledId1, AuraLedId ledId2) => !(ledId1 == ledId2); public static bool operator !=(AsusLedId ledId1, AsusLedId ledId2) => !(ledId1 == ledId2);
#endregion #endregion
} }

View File

@ -6,13 +6,13 @@ using System.Runtime.InteropServices;
using RGB.NET.Core; using RGB.NET.Core;
using RGB.NET.Core.Layout; using RGB.NET.Core.Layout;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic Aura-device. (keyboard, mouse, headset, mousepad). /// Represents a generic Asus-device. (keyboard, mouse, headset, mousepad).
/// </summary> /// </summary>
public abstract class AuraRGBDevice : AbstractRGBDevice public abstract class AsusRGBDevice : AbstractRGBDevice
{ {
#region Properties & Fields #region Properties & Fields
@ -23,7 +23,7 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Gets information about the <see cref="T:RGB.NET.Devices.Aura.AuraRGBDevice" />. /// Gets information about the <see cref="T:RGB.NET.Devices.Asus.AsusRGBDevice" />.
/// </summary> /// </summary>
public override IRGBDeviceInfo DeviceInfo { get; } public override IRGBDeviceInfo DeviceInfo { get; }
@ -32,10 +32,10 @@ namespace RGB.NET.Devices.Aura
#region Constructors #region Constructors
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="AuraRGBDevice"/> class. /// Initializes a new instance of the <see cref="AsusRGBDevice"/> class.
/// </summary> /// </summary>
/// <param name="info">The generic information provided by Aura for the device.</param> /// <param name="info">The generic information provided by Asus for the device.</param>
protected AuraRGBDevice(IRGBDeviceInfo info) protected AsusRGBDevice(IRGBDeviceInfo info)
{ {
this.DeviceInfo = info; this.DeviceInfo = info;
} }
@ -83,9 +83,9 @@ namespace RGB.NET.Devices.Aura
if (layout.Leds != null) if (layout.Leds != null)
foreach (LedLayout layoutLed in layout.Leds) foreach (LedLayout layoutLed in layout.Leds)
{ {
if (Enum.TryParse(layoutLed.Id, true, out AuraLedIds ledId)) if (Enum.TryParse(layoutLed.Id, true, out AsusLedIds ledId))
{ {
if (LedMapping.TryGetValue(new AuraLedId(this, ledId), out Led led)) if (LedMapping.TryGetValue(new AsusLedId(this, ledId), out Led led))
{ {
led.LedRectangle.Location.X = layoutLed.X; led.LedRectangle.Location.X = layoutLed.X;
led.LedRectangle.Location.Y = layoutLed.Y; led.LedRectangle.Location.Y = layoutLed.Y;
@ -114,7 +114,7 @@ namespace RGB.NET.Devices.Aura
{ {
foreach (Led led in leds) foreach (Led led in leds)
{ {
int index = (((AuraLedId)led.Id).Index) * 3; int index = (((AsusLedId)led.Id).Index) * 3;
ColorData[index] = led.Color.R; ColorData[index] = led.Color.R;
ColorData[index + 1] = led.Color.G; ColorData[index + 1] = led.Color.G;
ColorData[index + 2] = led.Color.B; ColorData[index + 2] = led.Color.B;
@ -132,7 +132,7 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
public override void Dispose() public override void Dispose()
{ {
if ((DeviceInfo is AuraRGBDeviceInfo deviceInfo) && (deviceInfo.Handle != IntPtr.Zero)) if ((DeviceInfo is AsusRGBDeviceInfo deviceInfo) && (deviceInfo.Handle != IntPtr.Zero))
Marshal.FreeHGlobal(deviceInfo.Handle); Marshal.FreeHGlobal(deviceInfo.Handle);
ColorData = null; ColorData = null;

View File

@ -1,13 +1,13 @@
using System; using System;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic information for a Corsair-<see cref="T:RGB.NET.Core.IRGBDevice" />. /// Represents a generic information for a Corsair-<see cref="T:RGB.NET.Core.IRGBDevice" />.
/// </summary> /// </summary>
public class AuraRGBDeviceInfo : IRGBDeviceInfo public class AsusRGBDeviceInfo : IRGBDeviceInfo
{ {
#region Properties & Fields #region Properties & Fields
@ -27,7 +27,7 @@ namespace RGB.NET.Devices.Aura
public RGBDeviceLighting Lighting => RGBDeviceLighting.Key; public RGBDeviceLighting Lighting => RGBDeviceLighting.Key;
/// <summary> /// <summary>
/// Gets the index of the <see cref="AuraRGBDevice"/>. /// Gets the index of the <see cref="AsusRGBDevice"/>.
/// </summary> /// </summary>
internal IntPtr Handle { get; } internal IntPtr Handle { get; }
@ -36,13 +36,13 @@ namespace RGB.NET.Devices.Aura
#region Constructors #region Constructors
/// <summary> /// <summary>
/// Internal constructor of managed <see cref="AuraRGBDeviceInfo"/>. /// Internal constructor of managed <see cref="AsusRGBDeviceInfo"/>.
/// </summary> /// </summary>
/// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param> /// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param>
/// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param> /// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param>
/// <param name="manufacturer">The manufacturer-name of the <see cref="IRGBDevice"/>.</param> /// <param name="manufacturer">The manufacturer-name of the <see cref="IRGBDevice"/>.</param>
/// <param name="model">The model-name of the <see cref="IRGBDevice"/>.</param> /// <param name="model">The model-name of the <see cref="IRGBDevice"/>.</param>
internal AuraRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle, string manufacturer = "Unknown", string model = "Generic Aura-Device") internal AsusRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle, string manufacturer = "Unknown", string model = "Generic Asus-Device")
{ {
this.DeviceType = deviceType; this.DeviceType = deviceType;
this.Handle = handle; this.Handle = handle;

View File

@ -1,20 +1,20 @@
using RGB.NET.Core; using RGB.NET.Core;
using RGB.NET.Devices.Aura.Native; using RGB.NET.Devices.Asus.Native;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a Aura graphicsCard. /// Represents a Asus graphicsCard.
/// </summary> /// </summary>
public class AuraGraphicsCardRGBDevice : AuraRGBDevice public class AsusGraphicsCardRGBDevice : AsusRGBDevice
{ {
#region Properties & Fields #region Properties & Fields
/// <summary> /// <summary>
/// Gets information about the <see cref="AuraGraphicsCardRGBDevice"/>. /// Gets information about the <see cref="AsusGraphicsCardRGBDevice"/>.
/// </summary> /// </summary>
public AuraGraphicsCardRGBDeviceInfo GraphicsCardDeviceInfo { get; } public AsusGraphicsCardRGBDeviceInfo GraphicsCardDeviceInfo { get; }
#endregion #endregion
@ -22,10 +22,10 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Aura.AuraGraphicsCardRGBDevice" /> class. /// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Asus.AsusGraphicsCardRGBDevice" /> class.
/// </summary> /// </summary>
/// <param name="info">The specific information provided by Aura for the graphics card.</param> /// <param name="info">The specific information provided by Asus for the graphics card.</param>
internal AuraGraphicsCardRGBDevice(AuraGraphicsCardRGBDeviceInfo info) internal AsusGraphicsCardRGBDevice(AsusGraphicsCardRGBDeviceInfo info)
: base(info) : base(info)
{ {
this.GraphicsCardDeviceInfo = info; this.GraphicsCardDeviceInfo = info;
@ -39,17 +39,17 @@ namespace RGB.NET.Devices.Aura
protected override void InitializeLayout() protected override void InitializeLayout()
{ {
//TODO DarthAffe 07.10.2017: Look for a good default layout //TODO DarthAffe 07.10.2017: Look for a good default layout
int ledCount = _AuraSDK.GetGPULedCount(GraphicsCardDeviceInfo.Handle); int ledCount = _AsusSDK.GetGPULedCount(GraphicsCardDeviceInfo.Handle);
for (int i = 0; i < ledCount; i++) for (int i = 0; i < ledCount; i++)
InitializeLed(new AuraLedId(this, AuraLedIds.GraphicsCardLed1 + i, i), new Rectangle(i * 10, 0, 10, 10)); InitializeLed(new AsusLedId(this, AsusLedIds.GraphicsCardLed1 + i, i), new Rectangle(i * 10, 0, 10, 10));
//TODO DarthAffe 07.10.2017: We don'T know the model, how to save layouts and images? //TODO DarthAffe 07.10.2017: We don'T know the model, how to save layouts and images?
ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Aura\GraphicsCards\{GraphicsCardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"), ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Asus\GraphicsCards\{GraphicsCardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"),
null, PathHelper.GetAbsolutePath(@"Images\Aura\GraphicsCards")); null, PathHelper.GetAbsolutePath(@"Images\Asus\GraphicsCards"));
} }
/// <inheritdoc /> /// <inheritdoc />
protected override void ApplyColorData() => _AuraSDK.SetGPUColor(GraphicsCardDeviceInfo.Handle, ColorData); protected override void ApplyColorData() => _AsusSDK.SetGPUColor(GraphicsCardDeviceInfo.Handle, ColorData);
#endregion #endregion
} }

View File

@ -1,26 +1,26 @@
using System; using System;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic information for a <see cref="T:RGB.NET.Devices.Aura.AuraGraphicsCardRGBDevice" />. /// Represents a generic information for a <see cref="T:RGB.NET.Devices.Asus.AsusGraphicsCardRGBDevice" />.
/// </summary> /// </summary>
public class AuraGraphicsCardRGBDeviceInfo : AuraRGBDeviceInfo public class AsusGraphicsCardRGBDeviceInfo : AsusRGBDeviceInfo
{ {
#region Constructors #region Constructors
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Internal constructor of managed <see cref="T:RGB.NET.Devices.Aura.AuraGraphicsCardRGBDeviceInfo" />. /// Internal constructor of managed <see cref="T:RGB.NET.Devices.Asus.AsusGraphicsCardRGBDeviceInfo" />.
/// </summary> /// </summary>
/// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param> /// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param>
/// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param> /// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param>
internal AuraGraphicsCardRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle) internal AsusGraphicsCardRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle)
: base(deviceType, handle) : base(deviceType, handle)
{ {
Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Aura\GraphicsCards\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute); Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Asus\GraphicsCards\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute);
} }
#endregion #endregion

View File

@ -1,20 +1,20 @@
using RGB.NET.Core; using RGB.NET.Core;
using RGB.NET.Devices.Aura.Native; using RGB.NET.Devices.Asus.Native;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a Aura keyboard. /// Represents a Asus keyboard.
/// </summary> /// </summary>
public class AuraKeyboardRGBDevice : AuraRGBDevice public class AsusKeyboardRGBDevice : AsusRGBDevice
{ {
#region Properties & Fields #region Properties & Fields
/// <summary> /// <summary>
/// Gets information about the <see cref="AuraKeyboardRGBDevice"/>. /// Gets information about the <see cref="AsusKeyboardRGBDevice"/>.
/// </summary> /// </summary>
public AuraKeyboardRGBDeviceInfo KeyboardDeviceInfo { get; } public AsusKeyboardRGBDeviceInfo KeyboardDeviceInfo { get; }
#endregion #endregion
@ -22,10 +22,10 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Aura.AuraKeyboardRGBDevice" /> class. /// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Asus.AsusKeyboardRGBDevice" /> class.
/// </summary> /// </summary>
/// <param name="info">The specific information provided by Aura for the keyboard.</param> /// <param name="info">The specific information provided by Asus for the keyboard.</param>
internal AuraKeyboardRGBDevice(AuraKeyboardRGBDeviceInfo info) internal AsusKeyboardRGBDevice(AsusKeyboardRGBDeviceInfo info)
: base(info) : base(info)
{ {
this.KeyboardDeviceInfo = info; this.KeyboardDeviceInfo = info;
@ -39,17 +39,17 @@ namespace RGB.NET.Devices.Aura
protected override void InitializeLayout() protected override void InitializeLayout()
{ {
//TODO DarthAffe 07.10.2017: Look for a good default layout //TODO DarthAffe 07.10.2017: Look for a good default layout
int ledCount = _AuraSDK.GetClaymoreKeyboardLedCount(KeyboardDeviceInfo.Handle); int ledCount = _AsusSDK.GetClaymoreKeyboardLedCount(KeyboardDeviceInfo.Handle);
for (int i = 0; i < ledCount; i++) for (int i = 0; i < ledCount; i++)
InitializeLed(new AuraLedId(this, AuraLedIds.KeyboardLed1 + i, i), new Rectangle(i * 19, 0, 19, 19)); InitializeLed(new AsusLedId(this, AsusLedIds.KeyboardLed1 + i, i), new Rectangle(i * 19, 0, 19, 19));
string model = KeyboardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper(); string model = KeyboardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper();
ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Aura\Keyboards\{model}\{KeyboardDeviceInfo.PhysicalLayout.ToString().ToUpper()}.xml"), ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Asus\Keyboards\{model}\{KeyboardDeviceInfo.PhysicalLayout.ToString().ToUpper()}.xml"),
KeyboardDeviceInfo.LogicalLayout.ToString(), PathHelper.GetAbsolutePath(@"Images\Aura\Keyboards")); KeyboardDeviceInfo.LogicalLayout.ToString(), PathHelper.GetAbsolutePath(@"Images\Asus\Keyboards"));
} }
/// <inheritdoc /> /// <inheritdoc />
protected override void ApplyColorData() => _AuraSDK.SetClaymoreKeyboardColor(KeyboardDeviceInfo.Handle, ColorData); protected override void ApplyColorData() => _AsusSDK.SetClaymoreKeyboardColor(KeyboardDeviceInfo.Handle, ColorData);
#endregion #endregion
} }

View File

@ -2,25 +2,25 @@
using System.Globalization; using System.Globalization;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic information for a <see cref="T:RGB.NET.Devices.Aura.AuraKeyboardRGBDevice" />. /// Represents a generic information for a <see cref="T:RGB.NET.Devices.Asus.AsusKeyboardRGBDevice" />.
/// </summary> /// </summary>
public class AuraKeyboardRGBDeviceInfo : AuraRGBDeviceInfo public class AsusKeyboardRGBDeviceInfo : AsusRGBDeviceInfo
{ {
#region Properties & Fields #region Properties & Fields
/// <summary> /// <summary>
/// Gets the physical layout of the keyboard. /// Gets the physical layout of the keyboard.
/// </summary> /// </summary>
public AuraPhysicalKeyboardLayout PhysicalLayout { get; private set; } public AsusPhysicalKeyboardLayout PhysicalLayout { get; private set; }
/// <summary> /// <summary>
/// Gets the logical layout of the keyboard. /// Gets the logical layout of the keyboard.
/// </summary> /// </summary>
public AuraLogicalKeyboardLayout LogicalLayout { get; private set; } public AsusLogicalKeyboardLayout LogicalLayout { get; private set; }
#endregion #endregion
@ -28,17 +28,17 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Internal constructor of managed <see cref="T:RGB.NET.Devices.Aura.AuraKeyboardRGBDeviceInfo" />. /// Internal constructor of managed <see cref="T:RGB.NET.Devices.Asus.AsusKeyboardRGBDeviceInfo" />.
/// </summary> /// </summary>
/// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param> /// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param>
/// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param> /// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param>
/// <param name="culture">The <see cref="T:System.Globalization.CultureInfo" /> of the layout this keyboard is using</param> /// <param name="culture">The <see cref="T:System.Globalization.CultureInfo" /> of the layout this keyboard is using</param>
internal AuraKeyboardRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle, CultureInfo culture) internal AsusKeyboardRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle, CultureInfo culture)
: base(deviceType, handle, "Asus", "Claymore") : base(deviceType, handle, "Asus", "Claymore")
{ {
SetLayouts(culture.KeyboardLayoutId); SetLayouts(culture.KeyboardLayoutId);
Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Aura\Keyboards\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute); Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Asus\Keyboards\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute);
} }
#endregion #endregion
@ -51,8 +51,8 @@ namespace RGB.NET.Devices.Aura
{ {
//TODO DarthAffe 07.10.2017: Implement //TODO DarthAffe 07.10.2017: Implement
default: default:
PhysicalLayout = AuraPhysicalKeyboardLayout.TODO; PhysicalLayout = AsusPhysicalKeyboardLayout.TODO;
LogicalLayout = AuraLogicalKeyboardLayout.TODO; LogicalLayout = AsusLogicalKeyboardLayout.TODO;
break; break;
} }
} }

View File

@ -1,20 +1,20 @@
using RGB.NET.Core; using RGB.NET.Core;
using RGB.NET.Devices.Aura.Native; using RGB.NET.Devices.Asus.Native;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a Aura mainboard. /// Represents a Asus mainboard.
/// </summary> /// </summary>
public class AuraMainboardRGBDevice : AuraRGBDevice public class AsusMainboardRGBDevice : AsusRGBDevice
{ {
#region Properties & Fields #region Properties & Fields
/// <summary> /// <summary>
/// Gets information about the <see cref="AuraMainboardRGBDevice"/>. /// Gets information about the <see cref="AsusMainboardRGBDevice"/>.
/// </summary> /// </summary>
public AuraMainboardRGBDeviceInfo MainboardDeviceInfo { get; } public AsusMainboardRGBDeviceInfo MainboardDeviceInfo { get; }
#endregion #endregion
@ -22,10 +22,10 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Aura.AuraMainboardRGBDevice" /> class. /// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Asus.AsusMainboardRGBDevice" /> class.
/// </summary> /// </summary>
/// <param name="info">The specific information provided by Aura for the mainboard.</param> /// <param name="info">The specific information provided by Asus for the mainboard.</param>
internal AuraMainboardRGBDevice(AuraMainboardRGBDeviceInfo info) internal AsusMainboardRGBDevice(AsusMainboardRGBDeviceInfo info)
: base(info) : base(info)
{ {
this.MainboardDeviceInfo = info; this.MainboardDeviceInfo = info;
@ -39,17 +39,17 @@ namespace RGB.NET.Devices.Aura
protected override void InitializeLayout() protected override void InitializeLayout()
{ {
//TODO DarthAffe 07.10.2017: Look for a good default layout //TODO DarthAffe 07.10.2017: Look for a good default layout
int ledCount = _AuraSDK.GetMbLedCount(MainboardDeviceInfo.Handle); int ledCount = _AsusSDK.GetMbLedCount(MainboardDeviceInfo.Handle);
for (int i = 0; i < ledCount; i++) for (int i = 0; i < ledCount; i++)
InitializeLed(new AuraLedId(this, AuraLedIds.MainboardAudio1 + i, i), new Rectangle(i * 40, 0, 40, 8)); InitializeLed(new AsusLedId(this, AsusLedIds.MainboardAudio1 + i, i), new Rectangle(i * 40, 0, 40, 8));
//TODO DarthAffe 07.10.2017: We don'T know the model, how to save layouts and images? //TODO DarthAffe 07.10.2017: We don'T know the model, how to save layouts and images?
ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Aura\Mainboards\{MainboardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"), ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Asus\Mainboards\{MainboardDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"),
null, PathHelper.GetAbsolutePath(@"Images\Aura\Mainboards")); null, PathHelper.GetAbsolutePath(@"Images\Asus\Mainboards"));
} }
/// <inheritdoc /> /// <inheritdoc />
protected override void ApplyColorData() => _AuraSDK.SetMbColor(MainboardDeviceInfo.Handle, ColorData); protected override void ApplyColorData() => _AsusSDK.SetMbColor(MainboardDeviceInfo.Handle, ColorData);
#endregion #endregion
} }

View File

@ -1,26 +1,26 @@
using System; using System;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic information for a <see cref="T:RGB.NET.Devices.Aura.AuraMainboardRGBDevice" />. /// Represents a generic information for a <see cref="T:RGB.NET.Devices.Asus.AsusMainboardRGBDevice" />.
/// </summary> /// </summary>
public class AuraMainboardRGBDeviceInfo : AuraRGBDeviceInfo public class AsusMainboardRGBDeviceInfo : AsusRGBDeviceInfo
{ {
#region Constructors #region Constructors
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Internal constructor of managed <see cref="T:RGB.NET.Devices.Aura.AuraMainboardRGBDeviceInfo" />. /// Internal constructor of managed <see cref="T:RGB.NET.Devices.Asus.AsusMainboardRGBDeviceInfo" />.
/// </summary> /// </summary>
/// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param> /// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param>
/// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param> /// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param>
internal AuraMainboardRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle) internal AsusMainboardRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle)
: base(deviceType, handle) : base(deviceType, handle)
{ {
Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Aura\Mainboards\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute); Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Asus\Mainboards\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute);
} }
#endregion #endregion

View File

@ -1,20 +1,20 @@
using RGB.NET.Core; using RGB.NET.Core;
using RGB.NET.Devices.Aura.Native; using RGB.NET.Devices.Asus.Native;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a Aura mouse. /// Represents a Asus mouse.
/// </summary> /// </summary>
public class AuraMouseRGBDevice : AuraRGBDevice public class AsusMouseRGBDevice : AsusRGBDevice
{ {
#region Properties & Fields #region Properties & Fields
/// <summary> /// <summary>
/// Gets information about the <see cref="AuraMouseRGBDevice"/>. /// Gets information about the <see cref="AsusMouseRGBDevice"/>.
/// </summary> /// </summary>
public AuraMouseRGBDeviceInfo MouseDeviceInfo { get; } public AsusMouseRGBDeviceInfo MouseDeviceInfo { get; }
#endregion #endregion
@ -22,10 +22,10 @@ namespace RGB.NET.Devices.Aura
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Aura.AuraMouseRGBDevice" /> class. /// Initializes a new instance of the <see cref="T:RGB.NET.Devices.Asus.AsusMouseRGBDevice" /> class.
/// </summary> /// </summary>
/// <param name="info">The specific information provided by Aura for the mouse.</param> /// <param name="info">The specific information provided by Asus for the mouse.</param>
internal AuraMouseRGBDevice(AuraMouseRGBDeviceInfo info) internal AsusMouseRGBDevice(AsusMouseRGBDeviceInfo info)
: base(info) : base(info)
{ {
this.MouseDeviceInfo = info; this.MouseDeviceInfo = info;
@ -39,16 +39,16 @@ namespace RGB.NET.Devices.Aura
protected override void InitializeLayout() protected override void InitializeLayout()
{ {
//TODO DarthAffe 07.10.2017: Look for a good default layout //TODO DarthAffe 07.10.2017: Look for a good default layout
int ledCount = _AuraSDK.GetRogMouseLedCount(MouseDeviceInfo.Handle); int ledCount = _AsusSDK.GetRogMouseLedCount(MouseDeviceInfo.Handle);
for (int i = 0; i < ledCount; i++) for (int i = 0; i < ledCount; i++)
InitializeLed(new AuraLedId(this, AuraLedIds.MouseLed1 + i, i), new Rectangle(i * 10, 0, 10, 10)); InitializeLed(new AsusLedId(this, AsusLedIds.MouseLed1 + i, i), new Rectangle(i * 10, 0, 10, 10));
ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Aura\Mouses\{MouseDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"), ApplyLayoutFromFile(PathHelper.GetAbsolutePath($@"Layouts\Asus\Mouses\{MouseDeviceInfo.Model.Replace(" ", string.Empty).ToUpper()}.xml"),
null, PathHelper.GetAbsolutePath(@"Images\Aura\Mouses")); null, PathHelper.GetAbsolutePath(@"Images\Asus\Mouses"));
} }
/// <inheritdoc /> /// <inheritdoc />
protected override void ApplyColorData() => _AuraSDK.SetRogMouseColor(MouseDeviceInfo.Handle, ColorData); protected override void ApplyColorData() => _AsusSDK.SetRogMouseColor(MouseDeviceInfo.Handle, ColorData);
#endregion #endregion
} }

View File

@ -1,26 +1,26 @@
using System; using System;
using RGB.NET.Core; using RGB.NET.Core;
namespace RGB.NET.Devices.Aura namespace RGB.NET.Devices.Asus
{ {
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Represents a generic information for a <see cref="T:RGB.NET.Devices.Aura.AuraMouseRGBDevice" />. /// Represents a generic information for a <see cref="T:RGB.NET.Devices.Asus.AsusMouseRGBDevice" />.
/// </summary> /// </summary>
public class AuraMouseRGBDeviceInfo : AuraRGBDeviceInfo public class AsusMouseRGBDeviceInfo : AsusRGBDeviceInfo
{ {
#region Constructors #region Constructors
/// <inheritdoc /> /// <inheritdoc />
/// <summary> /// <summary>
/// Internal constructor of managed <see cref="T:RGB.NET.Devices.Aura.AuraMouseRGBDeviceInfo" />. /// Internal constructor of managed <see cref="T:RGB.NET.Devices.Asus.AsusMouseRGBDeviceInfo" />.
/// </summary> /// </summary>
/// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param> /// <param name="deviceType">The type of the <see cref="IRGBDevice"/>.</param>
/// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param> /// <param name="handle">The handle of the <see cref="IRGBDevice"/>.</param>
internal AuraMouseRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle) internal AsusMouseRGBDeviceInfo(RGBDeviceType deviceType, IntPtr handle)
: base(deviceType, handle, "Asus", "Rog") : base(deviceType, handle, "Asus", "Rog")
{ {
Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Aura\Mouses\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute); Image = new Uri(PathHelper.GetAbsolutePath($@"Images\Asus\Mouses\{Model.Replace(" ", string.Empty).ToUpper()}.png"), UriKind.Absolute);
} }
#endregion #endregion

View File

@ -8,10 +8,10 @@ using System.Linq;
using System.Runtime.InteropServices; using System.Runtime.InteropServices;
using RGB.NET.Core.Exceptions; using RGB.NET.Core.Exceptions;
namespace RGB.NET.Devices.Aura.Native namespace RGB.NET.Devices.Asus.Native
{ {
// ReSharper disable once InconsistentNaming // ReSharper disable once InconsistentNaming
internal static class _AuraSDK internal static class _AsusSDK
{ {
#region Libary Management #region Libary Management
@ -27,18 +27,18 @@ namespace RGB.NET.Devices.Aura.Native
/// </summary> /// </summary>
internal static void Reload() internal static void Reload()
{ {
UnloadAuraSDK(); UnloadAsusSDK();
LoadAuraSDK(); LoadAsusSDK();
} }
private static void LoadAuraSDK() private static void LoadAsusSDK()
{ {
if (_dllHandle != IntPtr.Zero) return; if (_dllHandle != IntPtr.Zero) return;
// HACK: Load library at runtime to support both, x86 and x64 with one managed dll // HACK: Load library at runtime to support both, x86 and x64 with one managed dll
List<string> possiblePathList = Environment.Is64BitProcess ? AuraDeviceProvider.PossibleX64NativePaths : AuraDeviceProvider.PossibleX86NativePaths; List<string> possiblePathList = Environment.Is64BitProcess ? AsusDeviceProvider.PossibleX64NativePaths : AsusDeviceProvider.PossibleX86NativePaths;
string dllPath = possiblePathList.FirstOrDefault(File.Exists); string dllPath = possiblePathList.FirstOrDefault(File.Exists);
if (dllPath == null) throw new RGBDeviceException($"Can't find the Aura-SDK at one of the expected locations:\r\n '{string.Join("\r\n", possiblePathList.Select(Path.GetFullPath))}'"); if (dllPath == null) throw new RGBDeviceException($"Can't find the Asus-SDK at one of the expected locations:\r\n '{string.Join("\r\n", possiblePathList.Select(Path.GetFullPath))}'");
SetDllDirectory(Path.GetDirectoryName(Path.GetFullPath(dllPath))); SetDllDirectory(Path.GetDirectoryName(Path.GetFullPath(dllPath)));
@ -73,7 +73,7 @@ namespace RGB.NET.Devices.Aura.Native
//_getDramColorPointer = (GetDramColorPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "GetDramColor"), typeof(GetDramColorPointer)); //_getDramColorPointer = (GetDramColorPointer)Marshal.GetDelegateForFunctionPointer(GetProcAddress(_dllHandle, "GetDramColor"), typeof(GetDramColorPointer));
} }
private static void UnloadAuraSDK() private static void UnloadAsusSDK()
{ {
if (_dllHandle == IntPtr.Zero) return; if (_dllHandle == IntPtr.Zero) return;

View File

@ -4,11 +4,11 @@ using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following // General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information // set of attributes. Change these attribute values to modify the information
// associated with an assembly. // associated with an assembly.
[assembly: AssemblyTitle("RGB.NET.Devices.Aura")] [assembly: AssemblyTitle("RGB.NET.Devices.Asus")]
[assembly: AssemblyDescription("Aura-Device-Implementations of RGB.NET")] [assembly: AssemblyDescription("Asus-Device-Implementations of RGB.NET")]
[assembly: AssemblyConfiguration("")] [assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Wyrez")] [assembly: AssemblyCompany("Wyrez")]
[assembly: AssemblyProduct("RGB.NET.Devices.Aura")] [assembly: AssemblyProduct("RGB.NET.Devices.Asus")]
[assembly: AssemblyCopyright("Copyright © Wyrez 2017")] [assembly: AssemblyCopyright("Copyright © Wyrez 2017")]
[assembly: AssemblyTrademark("")] [assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")] [assembly: AssemblyCulture("")]

View File

@ -7,8 +7,8 @@
<ProjectGuid>{4F2F3FBD-A1E4-4968-A2AD-0514959E5E59}</ProjectGuid> <ProjectGuid>{4F2F3FBD-A1E4-4968-A2AD-0514959E5E59}</ProjectGuid>
<OutputType>Library</OutputType> <OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder> <AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>RGB.NET.Devices.Aura</RootNamespace> <RootNamespace>RGB.NET.Devices.Asus</RootNamespace>
<AssemblyName>RGB.NET.Devices.Aura</AssemblyName> <AssemblyName>RGB.NET.Devices.Asus</AssemblyName>
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion> <TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment> <FileAlignment>512</FileAlignment>
</PropertyGroup> </PropertyGroup>
@ -20,7 +20,7 @@
<DefineConstants>DEBUG;TRACE</DefineConstants> <DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<DocumentationFile>..\bin\RGB.NET.Devices.Aura.xml</DocumentationFile> <DocumentationFile>..\bin\RGB.NET.Devices.Asus.xml</DocumentationFile>
</PropertyGroup> </PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType> <DebugType>pdbonly</DebugType>
@ -29,7 +29,7 @@
<DefineConstants>TRACE</DefineConstants> <DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<DocumentationFile>..\bin\RGB.NET.Devices.Aura.xml</DocumentationFile> <DocumentationFile>..\bin\RGB.NET.Devices.Asus.xml</DocumentationFile>
</PropertyGroup> </PropertyGroup>
<ItemGroup> <ItemGroup>
<Reference Include="System" /> <Reference Include="System" />
@ -45,24 +45,24 @@
<Reference Include="System.Xml" /> <Reference Include="System.Xml" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="AuraDeviceProvider.cs" /> <Compile Include="AsusDeviceProvider.cs" />
<Compile Include="Dram\AuraDramRGBDevice.cs" /> <Compile Include="Dram\AsusDramRGBDevice.cs" />
<Compile Include="Dram\AuraDramRGBDeviceInfo.cs" /> <Compile Include="Dram\AsusDramRGBDeviceInfo.cs" />
<Compile Include="Enum\AuraLedIds.cs" /> <Compile Include="Enum\AsusLedIds.cs" />
<Compile Include="Enum\AuraLogicalKeyboardLayout.cs" /> <Compile Include="Enum\AsusLogicalKeyboardLayout.cs" />
<Compile Include="Enum\AuraPhysicalKeyboardLayout.cs" /> <Compile Include="Enum\AsusPhysicalKeyboardLayout.cs" />
<Compile Include="Generic\AuraRGBDevice.cs" /> <Compile Include="Generic\AsusRGBDevice.cs" />
<Compile Include="Generic\AuraLedId.cs" /> <Compile Include="Generic\AsusLedId.cs" />
<Compile Include="Generic\AuraRGBDeviceInfo.cs" /> <Compile Include="Generic\AsusRGBDeviceInfo.cs" />
<Compile Include="GraphicsCard\AuraGraphicsCardRGBDevice.cs" /> <Compile Include="GraphicsCard\AsusGraphicsCardRGBDevice.cs" />
<Compile Include="GraphicsCard\AuraGraphicsCardRGBDeviceInfo.cs" /> <Compile Include="GraphicsCard\AsusGraphicsCardRGBDeviceInfo.cs" />
<Compile Include="Keyboard\AuraKeyboardRGBDevice.cs" /> <Compile Include="Keyboard\AsusKeyboardRGBDevice.cs" />
<Compile Include="Keyboard\AuraKeyboardRGBDeviceInfo.cs" /> <Compile Include="Keyboard\AsusKeyboardRGBDeviceInfo.cs" />
<Compile Include="Mainboard\AuraMainboardRGBDevice.cs" /> <Compile Include="Mainboard\AsusMainboardRGBDevice.cs" />
<Compile Include="Mainboard\AuraMainboardRGBDeviceInfo.cs" /> <Compile Include="Mainboard\AsusMainboardRGBDeviceInfo.cs" />
<Compile Include="Mouse\AuraMouseRGBDevice.cs" /> <Compile Include="Mouse\AsusMouseRGBDevice.cs" />
<Compile Include="Mouse\AuraMouseRGBDeviceInfo.cs" /> <Compile Include="Mouse\AsusMouseRGBDeviceInfo.cs" />
<Compile Include="Native\_AuraSDK.cs" /> <Compile Include="Native\_AsusSDK.cs" />
<Compile Include="Properties\AssemblyInfo.cs" /> <Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
@ -70,7 +70,7 @@
<SubType>Designer</SubType> <SubType>Designer</SubType>
</None> </None>
<None Include="packages.config" /> <None Include="packages.config" />
<None Include="targets\RGB.NET.Devices.Aura.targets" /> <None Include="targets\RGB.NET.Devices.Asus.targets" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Content Include="libs\x86\AURA_SDK.dll" /> <Content Include="libs\x86\AURA_SDK.dll" />
@ -84,8 +84,8 @@
<Content Include="libs\x86\VGA_Extra.dll" /> <Content Include="libs\x86\VGA_Extra.dll" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Folder Include="Images\Aura\" /> <Folder Include="Images\Asus\" />
<Folder Include="Layouts\Aura\" /> <Folder Include="Layouts\Asus\" />
<Folder Include="libs\x64\" /> <Folder Include="libs\x64\" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>

View File

@ -12,7 +12,7 @@
--> -->
<ItemGroup> <ItemGroup>
<AuraSDKFiles Condition="'$(MSBuildThisFileDirectory)' != '' And <AsusSDKFiles Condition="'$(MSBuildThisFileDirectory)' != '' And
HasTrailingSlash('$(MSBuildThisFileDirectory)')" HasTrailingSlash('$(MSBuildThisFileDirectory)')"
Include="$(MSBuildThisFileDirectory)libs\**\*.dll;$(MSBuildThisFileDirectory)resources\**\*.*" /> Include="$(MSBuildThisFileDirectory)libs\**\*.dll;$(MSBuildThisFileDirectory)resources\**\*.*" />
@ -30,10 +30,10 @@
****************************************************************************** ******************************************************************************
--> -->
<ItemGroup Condition="'$(ContentAuraSDKFiles)' != '' And <ItemGroup Condition="'$(ContentAsusSDKFiles)' != '' And
'$(ContentAuraSDKFiles)' != 'false' And '$(ContentAsusSDKFiles)' != 'false' And
'@(AuraSDKFiles)' != ''"> '@(AsusSDKFiles)' != ''">
<Content Include="@(AuraSDKFiles)"> <Content Include="@(AsusSDKFiles)">
<Link>%(RecursiveDir)%(FileName)%(Extension)</Link> <Link>%(RecursiveDir)%(FileName)%(Extension)</Link>
<CopyToOutputDirectory>Always</CopyToOutputDirectory> <CopyToOutputDirectory>Always</CopyToOutputDirectory>
</Content> </Content>
@ -45,51 +45,51 @@
****************************************************************************** ******************************************************************************
--> -->
<Target Name="CopyAuraSDKFiles" <Target Name="CopyAsusSDKFiles"
Condition="'$(CopyAuraSDKFiles)' != 'false' And Condition="'$(CopyAsusSDKFiles)' != 'false' And
'$(OutDir)' != '' And '$(OutDir)' != '' And
HasTrailingSlash('$(OutDir)') And HasTrailingSlash('$(OutDir)') And
Exists('$(OutDir)')" Exists('$(OutDir)')"
Inputs="@(AuraSDKFiles)" Inputs="@(AsusSDKFiles)"
Outputs="@(AuraSDKFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')"> Outputs="@(AsusSDKFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')">
<!-- <!--
NOTE: Copy "AURA_SDK.dll" and all related files, for every NOTE: Copy "AURA_SDK.dll" and all related files, for every
architecture that we support, to the build output directory. architecture that we support, to the build output directory.
--> -->
<Message Text="Copying SDK files..." Importance="high" /> <Message Text="Copying SDK files..." Importance="high" />
<Copy SourceFiles="@(AuraSDKFiles)" <Copy SourceFiles="@(AsusSDKFiles)"
DestinationFiles="@(AuraSDKFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')" /> DestinationFiles="@(AsusSDKFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')" />
</Target> </Target>
<!-- <!--
****************************************************************************** ******************************************************************************
--> -->
<Target Name="CleanAuraSDKFiles" <Target Name="CleanAsusSDKFiles"
Condition="'$(CleanAuraSDKFiles)' != 'false' And Condition="'$(CleanAsusSDKFiles)' != 'false' And
'$(OutDir)' != '' And '$(OutDir)' != '' And
HasTrailingSlash('$(OutDir)') And HasTrailingSlash('$(OutDir)') And
Exists('$(OutDir)')"> Exists('$(OutDir)')">
<!-- <!--
NOTE: Delete "AuraSDK*.dll" and all related files, for every NOTE: Delete "AsusSDK*.dll" and all related files, for every
architecture that we support, from the build output directory. architecture that we support, from the build output directory.
--> -->
<Message Text="this file $(MSBuildThisFileDirectory)" Importance="high"/> <Message Text="this file $(MSBuildThisFileDirectory)" Importance="high"/>
<Message Text="Cleaning SDK files..." Importance="high" /> <Message Text="Cleaning SDK files..." Importance="high" />
<Delete Files="@(AuraSDKFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')" /> <Delete Files="@(AsusSDKFiles -> '$(OutDir)%(RecursiveDir)%(Filename)%(Extension)')" />
</Target> </Target>
<!-- <!--
****************************************************************************** ******************************************************************************
--> -->
<Target Name="CollectAuraSDKFiles" <Target Name="CollectAsusSDKFiles"
Condition="'$(CollectAuraSDKFiles)' != 'false'"> Condition="'$(CollectAsusSDKFiles)' != 'false'">
<Message Text="Collecting SDK files..." Importance="high" /> <Message Text="Collecting SDK files..." Importance="high" />
<ItemGroup> <ItemGroup>
<FilesForPackagingFromProject Include="@(AuraSDKFiles)"> <FilesForPackagingFromProject Include="@(AsusSDKFiles)">
<DestinationRelativePath>bin\%(RecursiveDir)%(Filename)%(Extension)</DestinationRelativePath> <DestinationRelativePath>bin\%(RecursiveDir)%(Filename)%(Extension)</DestinationRelativePath>
</FilesForPackagingFromProject> </FilesForPackagingFromProject>
</ItemGroup> </ItemGroup>
@ -120,15 +120,15 @@
<PropertyGroup> <PropertyGroup>
<PostBuildEventDependsOn> <PostBuildEventDependsOn>
$(PostBuildEventDependsOn); $(PostBuildEventDependsOn);
CopyAuraSDKFiles; CopyAsusSDKFiles;
</PostBuildEventDependsOn> </PostBuildEventDependsOn>
<BuildDependsOn> <BuildDependsOn>
$(BuildDependsOn); $(BuildDependsOn);
CopyAuraSDKFiles; CopyAsusSDKFiles;
</BuildDependsOn> </BuildDependsOn>
<CleanDependsOn> <CleanDependsOn>
$(CleanDependsOn); $(CleanDependsOn);
CleanAuraSDKFiles; CleanAsusSDKFiles;
</CleanDependsOn> </CleanDependsOn>
</PropertyGroup> </PropertyGroup>
@ -143,7 +143,7 @@
'$(VisualStudioVersion)' == '11.0' Or '$(VisualStudioVersion)' == '11.0' Or
'$(VisualStudioVersion)' == '12.0'"> '$(VisualStudioVersion)' == '12.0'">
<PipelineCollectFilesPhaseDependsOn> <PipelineCollectFilesPhaseDependsOn>
CollectAuraSDKFiles; CollectAsusSDKFiles;
$(PipelineCollectFilesPhaseDependsOn); $(PipelineCollectFilesPhaseDependsOn);
</PipelineCollectFilesPhaseDependsOn> </PipelineCollectFilesPhaseDependsOn>
</PropertyGroup> </PropertyGroup>

View File

@ -28,7 +28,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "NuGet", "NuGet", "{06416566
NuGet\RGB.NET.Brushes.nuspec = NuGet\RGB.NET.Brushes.nuspec NuGet\RGB.NET.Brushes.nuspec = NuGet\RGB.NET.Brushes.nuspec
NuGet\RGB.NET.Core.nuspec = NuGet\RGB.NET.Core.nuspec NuGet\RGB.NET.Core.nuspec = NuGet\RGB.NET.Core.nuspec
NuGet\RGB.NET.Decorators.nuspec = NuGet\RGB.NET.Decorators.nuspec NuGet\RGB.NET.Decorators.nuspec = NuGet\RGB.NET.Decorators.nuspec
NuGet\RGB.NET.Devices.Aura.nuspec = NuGet\RGB.NET.Devices.Aura.nuspec NuGet\RGB.NET.Devices.Asus.nuspec = NuGet\RGB.NET.Devices.Asus.nuspec
NuGet\RGB.NET.Devices.CoolerMaster.nuspec = NuGet\RGB.NET.Devices.CoolerMaster.nuspec NuGet\RGB.NET.Devices.CoolerMaster.nuspec = NuGet\RGB.NET.Devices.CoolerMaster.nuspec
NuGet\RGB.NET.Devices.Corsair.nuspec = NuGet\RGB.NET.Devices.Corsair.nuspec NuGet\RGB.NET.Devices.Corsair.nuspec = NuGet\RGB.NET.Devices.Corsair.nuspec
NuGet\RGB.NET.Devices.Logitech.nuspec = NuGet\RGB.NET.Devices.Logitech.nuspec NuGet\RGB.NET.Devices.Logitech.nuspec = NuGet\RGB.NET.Devices.Logitech.nuspec
@ -56,7 +56,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RGB.NET.Decorators", "RGB.N
{5A4F9A75-75FE-47CD-90E5-914D5B20D232} = {5A4F9A75-75FE-47CD-90E5-914D5B20D232} {5A4F9A75-75FE-47CD-90E5-914D5B20D232} = {5A4F9A75-75FE-47CD-90E5-914D5B20D232}
EndProjectSection EndProjectSection
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RGB.NET.Devices.Aura", "RGB.NET.Devices.Aura\RGB.NET.Devices.Aura.csproj", "{4F2F3FBD-A1E4-4968-A2AD-0514959E5E59}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RGB.NET.Devices.Asus", "RGB.NET.Devices.Asus\RGB.NET.Devices.Asus.csproj", "{4F2F3FBD-A1E4-4968-A2AD-0514959E5E59}"
EndProject EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RGB.NET.Devices.Msi", "RGB.NET.Devices.Msi\RGB.NET.Devices.Msi.csproj", "{4EFD77C7-FDB4-4C6B-970C-0EF66D24BE09}" Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RGB.NET.Devices.Msi", "RGB.NET.Devices.Msi\RGB.NET.Devices.Msi.csproj", "{4EFD77C7-FDB4-4C6B-970C-0EF66D24BE09}"
EndProject EndProject