Page 1 of 1

[posila] [0.18.46] Crash when having big image in a mod for normal size

Posted: Tue Aug 11, 2020 7:32 pm
by timboo07up
To reproduce.

- have sprite settings set to normal
- have the max memory set at 2048 for the atlas.

Use the following mod (might need to install the dependencies).

Full factorio crash is in the logs as well.

It probably crashes on the sprite size.

Re: [posila] [0.18.46] Crash when having big image in a mod for normal size

Posted: Wed Aug 12, 2020 1:07 pm
by posila
Hmm ... it is actually "not-compressed" flag on the sprite that's causing it (I think), or the combination of the flag and the size. But I'll need to look into what's happening there. Until it is fixed, I suggest removing the flag. But the images are mostly transparent with thick lines of single color, so that should compress nearly losslessly, so I would not disable compression on them even after it is fixed.

Re: [posila] [0.18.46] Crash when having big image in a mod for normal size

Posted: Wed Aug 12, 2020 2:21 pm
by timboo07up
The problem with the compression was: it would compress them all down to 1 image in the atlas if i allowed compression.
Which would only give me a single image that has a red border on all sides, not all the different combinations that are possible.

For now i'm not looking for a fix, but was asked by bilka to report this here so it can be looked into.
As i would not expect a hardcrash from this, but maybe a: mod x crashed because of an image that was too big (or something more descriptive).

To give a small explanation of the mod's functions:
It generates an image on every chunk that can be "bought". When its bought the surrounding borders should be green (to give a better indication its buildable).
When i allow the compression they stay red, so it wasn't an option.

Anyhow, just wanted to help to make it even more crash proof :)
Also: if there is no solution for it, its fine as well for me. I can always work around it.

Re: [posila] [0.18.46] Crash when having big image in a mod for normal size

Posted: Fri Nov 06, 2020 8:46 am
by posila
Thanks for the report.
Fixed for 1.1

I am still little bit confused about what you said about the compression. There is no sprite deduplication logic, so the game never "compresses" different images into one image if they are similar or for any other reason, so you should be able to use compression. If you can reproduce that issue and send me a save and the mod, I'd like to look into that.