react-native-image-gallery icon indicating copy to clipboard operation
react-native-image-gallery copied to clipboard

Anyone tested for large amount of images array?

Open TayfunCesur opened this issue 6 years ago • 8 comments

Is there anyone tested for hundreds of images array ? I have tested an image array that is about 100-150 lenght. And after some sliding I saw all slided image still in memory and not going anywhere even if you slide 10 pages. I did some research about this issue and this problem caused by maybe ViewPagerAndroid. I can provide some simple example of this issue very soon. Thanks

TayfunCesur avatar Jun 27 '18 14:06 TayfunCesur

I have and it's crashing on me tested on 40+ images

justinsoong avatar Aug 09 '18 01:08 justinsoong

I really can't understand how all images sitting in memory after many many pages slided ? It seems ViewPagerAndroid bugs ?

TayfunCesur avatar Aug 09 '18 06:08 TayfunCesur

@TayfunCesur @justinsoong Did you try with 2.1.4? I think it was working quite OK with lots of images.

vbuch avatar Aug 30 '18 07:08 vbuch

I also have 40+ images, but for the some images they not able to load and display 'Image cannot ..' message on the real device.

kukadiajayesh avatar Oct 28 '18 13:10 kukadiajayesh

@kukadiajayesh you are probably running into memory issues. You need to reduce the amount of content you are showing and keeping rendered at once.

vbuch avatar Oct 28 '18 22:10 vbuch

@vbuch ofc we got oom errors. But if you are developing a photo gallery app, how do you reduce the amount? It's also unknown!

TayfunCesur avatar Nov 02 '18 19:11 TayfunCesur

@TayfunCesur I'd say that if you are developing a photo app, you should be doing a native approach and not react native that adds on top of your already limited resources. You could ttry reducing the sizes of the rendered images. Also make sure you are not leaving stacked screens on top of each other. Every thing that reduces the amount of memory you can use is a point for you to play... react-native-image-gallery is great but it cannot be a full-featured gallery app...

vbuch avatar Nov 02 '18 23:11 vbuch

We were having this exact issue with image arrays > 10 in size. The tenth image would work fine on simulator / phone - but not the 11th onwards. This is specific to version 2.1.5; but for the same set of images, 2.1.4 works perfectly - as mentioned by @vbuch

mitesh-mokko avatar Nov 15 '19 19:11 mitesh-mokko