Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Displaying an image gallery with Forms.Labs

$
0
0

One app I'm making now requires letting the user take pictures, then scroll through the list of pictures and generate a preview of each one they tap on.

So far I've got this in in theory, and on iOS it seems to work fine. I'm using Forms Labs to access the camera on Android and iOS, and it saves the image fine. The main problem I'm running into on android is that I seem to be quickly running out of memory. Even taking a single picture in this way and setting the image.Source to the stream of the returned mediafile from the picker immediately fills memory pretty severely:

[dalvikvm-heap] Grow heap (frag case) to 47.041MB for 31961104-byte allocation.

Etc.

Even just loading a fresh stream and assigning it to the same Image.Source seems capable of running up the memory. And this seems Android specific - then again that could just be because iOS has more memory at its disposal and isn't reporting this kind of thing.


Viewing all articles
Browse latest Browse all 58056

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>