# Maximum number of Image / FileImageSource File

**URL:** https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611
**Category:** Bug Reports
**Created:** [July 6, 2016, 8:32am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611 "2016-07-06T08:32:10Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![Vicker\_Leung](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vicker_leung/32/392_2.png) [@Vicker\_Leung](https://forums.fusetools.com/u/Vicker_Leung)
#### Post date: [July 6, 2016, 8:32am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/1 "2016-07-06T08:32:10Z")

</div>

Is there currently a limit of the number of `<Image File="" />` and `<MultiDensityImageSource><FileImageSource File="" /></MultiDensityImageSource>` in a project?

It may sounds weird, but that’s what I am currently facing. My project have around 300 `<Image File="" />` and `<MultiDensityImageSource><FileImageSource File="" /></MultiDensityImageSource>`. Whenever I try to add more, the project will fail to launch in preview, stucking at the “Loading Starting project…” screen. To make it running again, simply remove some random `<Image File="" />` or `<FileImageSource File="" />` in the project.

There are no compilation / runtime error messages. Log file don’t have any special messages. Tried `uno clean`.

Tested on 2 Mac OS X 10.11.5. Tested Fuse 0.21 and 0.20.3.

---

<div class="post-metadata">

### Author: ![Baggers](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/baggers/32/665_2.png) [@Baggers](https://forums.fusetools.com/u/Baggers)
#### Post date: [July 11, 2016, 11:13am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/2 "2016-07-11T11:13:36Z")

</div>

Ouch, sorry to hear about your issue Vicker,

There isnt a hard limit per-se but there are limitation on how much memory an app is reasonably allowed to use (especially when your app goes to the background).

Currently we don’t have a way to handle this automatically in an `Each` but it is on our roadmap. You will probably want to remove items that are offscreen but this is currently non trivial.

I will add this thread to the internal ticket though so it is not forgotten.

Thanks for asking

---

<div class="post-metadata">

### Author: ![Vicker\_Leung](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vicker_leung/32/392_2.png) [@Vicker\_Leung](https://forums.fusetools.com/u/Vicker_Leung)
#### Post date: [July 12, 2016, 2:19am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/3 "2016-07-12T02:19:24Z")

</div>

Thanks, Chris.

May I know approximately how much memory is allowed?

I checked my app design. Although the maximum number of `Image` shown in the `Each` can go beyond 300. When the app first launched, it only shows 20 and each JPEG is around 20KB. Adding on top some static multidensity icons (around 7). I guess all together it is hard to reach 1MB.

Is it possible that the limitation not only applies to runtime memory, but also the bundled assets?

---

<div class="post-metadata">

### Author: ![Vicker\_Leung](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vicker_leung/32/392_2.png) [@Vicker\_Leung](https://forums.fusetools.com/u/Vicker_Leung)
#### Post date: [July 14, 2016, 2:52am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/4 "2016-07-14T02:52:33Z")

</div>

Hi Chris,

My team tested the same code base on 2 Windows platform and it works great. Looks like it is a platform dependent issue.

If you wish, I can privately share our Git repository on GitHub to you to have a test.

---

<div class="post-metadata">

### Author: ![Baggers](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/baggers/32/665_2.png) [@Baggers](https://forums.fusetools.com/u/Baggers)
#### Post date: [July 22, 2016, 12:18pm UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/5 "2016-07-22T12:18:50Z")

</div>

Sorry for the slow response. Good to hear you made progress. I was under the assumption that this was a mobile/tablet issue, but by mentioning ‘Windows’ I’m wondering, is this was a desktop preview issue?

---

<div class="post-metadata">

### Author: ![Vicker\_Leung](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vicker_leung/32/392_2.png) [@Vicker\_Leung](https://forums.fusetools.com/u/Vicker_Leung)
#### Post date: [July 23, 2016, 3:45am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/6 "2016-07-23T03:45:40Z")

</div>

Hi Chris,

Sorry that I didn’t mention that the issue is related to “desktop preview”.

---

<div class="post-metadata">

### Author: ![Baggers](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/baggers/32/665_2.png) [@Baggers](https://forums.fusetools.com/u/Baggers)
#### Post date: [July 25, 2016, 11:00am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/7 "2016-07-25T11:00:57Z")

</div>

No worries,

There isnt a set limit to the `Image`s allowed in an `Each` in the simulator.

As this is platform dependent then I think I will let the tool’s folks know that we could do with some extra stress testing on the desktop preview. It would be great to see your test.

Is it ok if I mark this as resolved? (as this is a more general long-term issue, rather than a bug in the strict sense)

---

<div class="post-metadata">

### Author: ![Vicker\_Leung](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vicker_leung/32/392_2.png) [@Vicker\_Leung](https://forums.fusetools.com/u/Vicker_Leung)
#### Post date: [July 27, 2016, 7:40am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/8 "2016-07-27T07:40:43Z")

</div>

Sure. No problem.

I recorded a video showing the problem, please feel free to pass it to the tool team. [https://www.dropbox.com/s/8ozgy8nvl4f8f3y/fuse-image-issue.mp4?dl=0](https://www.dropbox.com/s/8ozgy8nvl4f8f3y/fuse-image-issue.mp4?dl=0)

Thanks, Chris.

---

<div class="post-metadata">

### Author: ![Baggers](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/baggers/32/665_2.png) [@Baggers](https://forums.fusetools.com/u/Baggers)
#### Post date: [August 5, 2016, 8:15am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/9 "2016-08-05T08:15:47Z")

</div>

Love it, thanks!

---

<div class="post-metadata">

### Author: ![Vicker\_Leung](https://yyz1.discourse-cdn.com/flex035/user_avatar/forums.fusetools.com/vicker_leung/32/392_2.png) [@Vicker\_Leung](https://forums.fusetools.com/u/Vicker_Leung)
#### Post date: [October 6, 2016, 3:05am UTC](https://forums.fusetools.com/t/maximum-number-of-image-fileimagesource-file/611/10 "2016-10-06T03:05:55Z")

</div>

Anders suggested a workaround and it works perfectly. Just for others references.

The issue is related to the maximum number of files opened in OSX for fuse preview. The workaround is to increase the limit by typing the following in the terminal.

```auto
ulimit -n 2048

```
