• Bugs
  • NullPointerException in texture packer

Related Discussions
...

I am getting a NullPointerException in texture packer. Spine log is attached. I can send you files that result in this error in private, if you need.

Error happens if I am trying to pack one or more 2046x487 images into 2048x2048 atlas (height actually does not matter).

Thanks. I downloaded and deleted the file, since it had your email address. The forum scrubs emails from posts, but not attachments.

I found the problem and fixed it for v3. Cheers! The images were too big and it wasn't detecting that. The image is too big because you have edge padding checked. 2046 image width + 2 padding on left + 2 padding on right > 2048 max width.

Thanks! Actually, when I have tried to use 2048, he told me that image is too big (2050). So I have found a difference 2050-2048=2 and subtracted it from the image size - this got me 2046. But then Spine reported NullPointerException.


Could you also take a look at this bug: https://github.com/EsotericSoftware/spine-runtimes/issues/478 ?

Aye, I also fixed the error message reporting the wrong size.

I assume you are using 2px edge padding. 2px on each edge is 4px. So the max width is 4px + image width. If image width is 2046, the max size must be >= 2050 (or turn off edge padding).