1

we are building an ionic app to show layers on maps using openlayers. Everything is working well on android but on ios when we load the second project we will have the following warning. warning: Total canvas memory use exceeds the maximum limit (224 MB)

I googled it, I think that the problem on ios is caching canvas of the map and when exceed the 224MB the app don’t crash but all layers are hidden on map and gives the above warning.

So is there any way to not cache canvas on ios using ionic? or is there any way also in openlayers?

I will appreciate your help.

thank you in advance.

Ali Wehbi
  • 69
  • 1
  • 11

2 Answers2

0

just reduce the total number of items being drawn on the canvas by combine mutiple static layers on the map into single image at server-side e.g. GeoServer then draw it as a Tiled layer.

there are similar questions on the same memory usage problem, however the canvas in yours ionic app should be encapsulated by the the Openlayer, making the workaround mentioned unlikely to work with your case.

0

I have found a workaround to try to always keep the canvas memory below its maximum limit to avoid rendering problems in the VectorTile layers, I have created a pull request here