How to reduce memory usage of Image.load()


#1

I have a problem with high memory usage when I upgrade aspose-imaging:

Version 2.1.0.0 loading the PSD = 100MB memory usage
Version 19.7 loading the PSD = 850MB memory usage

Same thing happens for TIF files.

Here’s an example PSD file: https://all-free-download.com/free-psd/download/white-3d-text-effect_6842064.html

com.aspose.imaging.imageloadoptions.PsdLoadOptions loadOptions = new com.aspose.imaging.imageloadoptions.PsdLoadOptions();
loadOptions.setReadOnlyMode(true);
com.aspose.imaging.Image image = com.aspose.imaging.Image.load(in, loadOptions);

setReadOnlyMode(true) has helped a lot with performance, but memory usage is still too high.

I’ve tried using the other setters in PsdLoadOptions, but nothing makes the memory usage lower.

I want the memory usage of Image.load() to be 100MB again. Is this possible? Is there something I’m missing?

I have also tried aspose-psd, the memory usage is still 850MB (too high).

Thanks!


#2

@atlassian

I have observed your requirements and have created an issue with ID IMAGINGJAVA-1386 as investigation to further investigate the issue on our end. This thread has been linked with the issue so that you may be notified once the issue will be fixed.