From 4f65fd1d1e5f3e0105b9054733f76f2af5c39b68 Mon Sep 17 00:00:00 2001 From: Jason Heard Date: Sat, 10 Aug 2019 12:15:58 -0600 Subject: [PATCH] Add test from issue #928 --- .../Drawing/FillRegionProcessorTests.cs | 26 +++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/tests/ImageSharp.Tests/Drawing/FillRegionProcessorTests.cs b/tests/ImageSharp.Tests/Drawing/FillRegionProcessorTests.cs index 5320a58a6..972f5cf4a 100644 --- a/tests/ImageSharp.Tests/Drawing/FillRegionProcessorTests.cs +++ b/tests/ImageSharp.Tests/Drawing/FillRegionProcessorTests.cs @@ -69,6 +69,32 @@ namespace SixLabors.ImageSharp.Tests.Drawing } } + [Fact] + public void DoesNotThrowForIssue928() + { + var rectText = new RectangleF(0, 0, 2000, 2000); + using (Image img = new Image((int)rectText.Width, (int)rectText.Height)) + { + img.Mutate(x => x.Fill(Rgba32.Transparent)); + + img.Mutate(ctx => { + ctx.DrawLines( + Rgba32.Red, + 0.984252f, + new PointF(104.762581f, 1074.99365f), + new PointF(104.758667f, 1075.01721f), + new PointF(104.757675f, 1075.04114f), + new PointF(104.759628f, 1075.065f), + new PointF(104.764488f, 1075.08838f), + new PointF(104.772186f, 1075.111f), + new PointF(104.782608f, 1075.13245f), + new PointF(104.782608f, 1075.13245f) + ); + } + ); + } + } + [Fact] public void DoesNotThrowFillingTriangle() {