I am using SVGKit to render the SVG which has a lot of embedded Base64 encoded png images in it.The problem is that the rendering takes around a minute which is terribly slowing down my app and uses a large amount of memory.The total size of the SVG is 10MB and at rendering the memory used is around 80-85 MB.Is there any way to get through it?
I have tried caching but memory issues still come up.
PNG is a compressed file format - it is guaranteed to use more memory when you display it. This is a fundamental limit of PNG; if you want to reduce memory usage, stop using PNGs, and instead include only vector graphics in your SVG.
Additionally, Apple usually stores extra information for each PNG to optimize the rendering speed.
(SVGKit may be storing extra info too, for the same reason: to increase rendering speed. But first you have to find out how big the PNGs are in memory)