Terra (Fabric/Forge/Paper)

Terra (Fabric/Forge/Paper)

74.2k Downloads

Large image support

Gal1leooo opened this issue ยท 6 comments

commented

Describe the issue

There is an error when i try to generate a world using provider type: image
The image is 25000x25000
Error: https://mclo.gs/MIY81FW

The files were .yml but i can't upload them, so i converted in txt
image.txt
pack.txt

commented

Send the entire pack folder, including the image you used. Zip all the files, so you can upload them as a single file.

commented

I believe the issue is with how the image is being loaded via Java's BufferedImage class, specifically that exception seems to be thrown when images are too large to be stored in memory (since each image sample point is stored in an array limited by the max integer size)

A solution would be to implement image stitching (which would be invisible to users) in the backend for images that are too large, such that they can be loaded into memory as multiple smaller BufferedImages.

commented

I would recommend implementing on top of #356 if anyone else wishes to work on this

commented

Thanks so much for the support! Still need the full pack? In case I'd prefer to send it in private.
If I may ask, how soon will this bug be fixed?

commented

hope #356 doesnt get stale. rn, I think the image provider is not usable

commented

Stitching implemented in 6efff02