First attempt to rewrite Effects

This commit is contained in:
DarthAffe committed 2016-08-21 13:11:07 +02:00
1 parent 5a296dd048
commit ba80ef9848
32 files changed
+353 -325

No files matched your search

+2 -1
View File
@@ -2,6 +2,7 @@
using System.Drawing;
using CUE.NET.Devices.Keyboard.Enums;
using CUE.NET.Effects;
using CUE.NET.Helper;
namespace CUE.NET.Brushes
@@ -9,7 +10,7 @@ namespace CUE.NET.Brushes
/// <summary>
/// Represents a basic brush.
/// </summary>
public abstract class AbstractBrush : IBrush
public abstract class AbstractBrush : AbstractEffectTarget<IBrush>, IBrush
{
#region Properties & Fields
+2 -1
View File
@@ -2,13 +2,14 @@
using System.Drawing;
using CUE.NET.Devices.Keyboard.Enums;
using CUE.NET.Effects;
namespace CUE.NET.Brushes
{
/// <summary>
/// Represents a basic brush.
/// </summary>
public interface IBrush
public interface IBrush : IEffectTarget<IBrush>
{
/// <summary>
/// Gets or sets the calculation mode used for the rectangle/points used for color-selection in brushes.
+2
View File
@@ -39,6 +39,8 @@ namespace CUE.NET.Brushes
#region Properties & Fields
protected override IBrush EffectTarget => this;
/// <summary>
/// Gets or sets the image drawn by the brush. If null it will default to full transparent.
/// </summary>
+2
View File
@@ -18,6 +18,8 @@ namespace CUE.NET.Brushes
{
#region Properties & Fields
protected override IBrush EffectTarget => this;
/// <summary>
/// Gets or sets the start point (as percentage in the range [0..1]) of the gradient drawn by the brush. (default: 0f, 0.5f)
/// </summary>
+3 -1
View File
@@ -11,7 +11,9 @@ namespace CUE.NET.Brushes
public class ProfileBrush : AbstractBrush
{
#region Properties & Fields
protected override IBrush EffectTarget => this;
private Dictionary<CorsairKeyboardKeyId, Color> _keyLights;
#endregion
+2
View File
@@ -16,6 +16,8 @@ namespace CUE.NET.Brushes
{
#region Properties & Fields
protected override IBrush EffectTarget => this;
/// <summary>
/// Gets or sets the center point (as percentage in the range [0..1]) around which the brush should be drawn.
/// </summary>
+2
View File
@@ -15,6 +15,8 @@ namespace CUE.NET.Brushes
{
#region Properties & Fields
protected override IBrush EffectTarget => this;
private Random _random = new Random();
#endregion
+2
View File
@@ -12,6 +12,8 @@ namespace CUE.NET.Brushes
{
#region Properties & Fields
protected override IBrush EffectTarget => this;
/// <summary>
/// Gets or sets the color drawn by the brush.
/// </summary>