Core - Simplified and improved render scaling

This commit is contained in:
SpoinkyNL committed 2020-12-08 22:54:54 +01:00
1 parent 18359c443f
commit 186d012087
10 files changed
+63 -99

No files matched your search

@@ -1,5 +1,6 @@
using System.Text;
using RGB.NET.Core;
using SkiaSharp;
namespace Artemis.Core
{
@@ -20,4 +21,17 @@ namespace Artemis.Core
return builder.ToString();
}
}
internal static class RgbRectangleExtensions
{
public static SKRect ToSKRect(this Rectangle rectangle)
{
return SKRect.Create(
(float) rectangle.Location.X,
(float) rectangle.Location.Y,
(float) rectangle.Size.Width,
(float) rectangle.Size.Height
);
}
}
}