mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-12 11:56:30 +00:00
Corsair - Added VOID layout and Virtuoso PH layout
Core - Added default value to brush plugin properties Core - Bitmap brush optimizations
This commit is contained in:
1 parent
1a0d5dafd1
commit
24f34f76b4
9 files changed
+151
-18
No files matched your search
@@ -67,8 +67,8 @@ namespace Artemis.Core.Models.Profile
|
||||
public ReadOnlyCollection<ArtemisLed> Leds => _leds.AsReadOnly();
|
||||
|
||||
/// <summary>
|
||||
/// A path containing all the LEDs this layer is applied to, any rendering outside the layer Path is clipped.
|
||||
/// <para>For rendering, use the Path on <see cref="LayerShape" />.</para>
|
||||
/// Gets a copy of the path containing all the LEDs this layer is applied to, any rendering outside the layer Path is
|
||||
/// clipped.
|
||||
/// </summary>
|
||||
public SKPath Path
|
||||
{
|
||||
@@ -211,6 +211,7 @@ namespace Artemis.Core.Models.Profile
|
||||
|
||||
#region Rendering
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void Update(double deltaTime)
|
||||
{
|
||||
foreach (var property in Properties)
|
||||
@@ -231,6 +232,7 @@ namespace Artemis.Core.Models.Profile
|
||||
LayerBrush?.Update(deltaTime);
|
||||
}
|
||||
|
||||
/// <inheritdoc />
|
||||
public override void Render(double deltaTime, SKCanvas canvas, SKImageInfo canvasInfo)
|
||||
{
|
||||
if (Path == null || LayerShape?.Path == null)
|
||||
|
||||
@@ -4,6 +4,8 @@ namespace Artemis.Core.Models.Profile.LayerShapes
|
||||
{
|
||||
public abstract class LayerShape
|
||||
{
|
||||
private SKPath _path;
|
||||
|
||||
protected LayerShape(Layer layer)
|
||||
{
|
||||
Layer = layer;
|
||||
@@ -15,9 +17,13 @@ namespace Artemis.Core.Models.Profile.LayerShapes
|
||||
public Layer Layer { get; set; }
|
||||
|
||||
/// <summary>
|
||||
/// A path outlining the shape
|
||||
/// Gets a copy of the path outlining the shape
|
||||
/// </summary>
|
||||
public SKPath Path { get; protected set; }
|
||||
public SKPath Path
|
||||
{
|
||||
get => _path != null ? new SKPath(_path) : null;
|
||||
protected set => _path = value;
|
||||
}
|
||||
|
||||
public abstract void CalculateRenderProperties();
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user