zkweb-framework / ZKWeb.System.Drawing

.Net Core compatible System.Drawing implementation modified from mono project.
Other
106 stars 23 forks source link

System.OutOfMemoryException throws when i tried to run the code on ubuntu #13

Open Milkitic opened 6 years ago

Milkitic commented 6 years ago

Hello. The project itself is an ASP.NET Core Application, and I wish to draw some images with more code. On Windows it runs normally when I start the program with "dotnet xxxx.dll" but on Ubuntu it was crash while the systemis available for about 1316000KB memory. I tried to reduce the code a little and it runs normally. But how to solve it if i want to keep the code length?

System.OutOfMemoryException: Not enough memory to complete operation [GDI+ status: OutOfMemory]
   at System.DrawingCore.GDIPlus.CheckStatus(Status status)
   at System.DrawingCore.Graphics.DrawLine(Pen pen, PointF pt1, PointF pt2)
   at Daylily.Plugin.Command.PpPlus.Draw(String user, Dictionary`2 d_pfmance)
   at Daylily.Plugin.Command.PpPlus.Execute(String params, String user, String group, Boolean isRoot)
303248153 commented 6 years ago

Please try the official system.drawing package for .net core, soon it will replace this fork. https://www.nuget.org/packages/System.Drawing.Common