Page 1 of 1

Looking for ways to control (limit) resource usage in Magick.NET

Posted: 2018-02-16T13:54:47-07:00
by Keith.Vinson
I am looking for the correct way to set the max memory and max pixel cache sizes preferably in code, but barring that should I use the policy.xml file by uncommenting the following lines and adjusting the values like this:

<policy domain="resource" name="memory" value="0MiB"/>
<policy domain="resource" name="map" value="0MiB"/>

I looked at the using something like this:
MagickReadSettings settings = new MagickReadSettings();
but I don't see the resource limits I'm looking to control.

Any help would be much appreciated, thanks...

Re: Looking for ways to control (limit) resource usage in Magick.NET

Posted: 2018-02-18T11:32:20-07:00
by dlemstra
You can find an example on how to do that here: https://github.com/dlemstra/Magick.NET/ ... iles-class