Program takes too much memory

走远了吗. 提交于 2019-11-29 16:30:13

This is the result of using a DrawingContext/DrawingVisual. It's actually benign and should all be garbage collected as the system needs it, but the memory usage can be alarming. If you were to, instead, draw shapes on a canvas then you would probably not see this problem. I've run into this same issue with custom drawn controls in the past. Switching to more vector-based drawing techniques (i.e., shapes on a canvas) fixed the memory consumption problem.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!