You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TextureAtlas.AtlasRegion has the fields "pads" and "splits" for 9-patch information.
These fields get populated if the info is loaded from a .atlas file with the TextureAtlas (FileHandle packFile) constructor.
However, if you use TexturePacker.pack or PixmapPacker.pack to pack your TextureAtlas at runtime using the generateTextureAtlas method, this 9-patch information is lost. There's no way to give TexturePacker or PixmapPacker this information when packing.
I would suggest that there should be a version of the pack methods in TexturePacker and PixmapPacker which accepts this 9-patch info so that it comes out in the regions from generateTextureAtlas.
Reproduction steps/code
I wrote a sort of workaround in this code here which assumes the user will be packing from only one TextureAtlas and that all the names of all the textures will exactly match. However, this is an ugly hack. It would be better if TexturePacker and PixmapPacker handled this.
Version of LibGDX and/or relevant dependencies
All.
Please select the affected platforms
All platforms.
The text was updated successfully, but these errors were encountered:
Issue details
TextureAtlas.AtlasRegion has the fields "pads" and "splits" for 9-patch information.
These fields get populated if the info is loaded from a .atlas file with the TextureAtlas (FileHandle packFile) constructor.
However, if you use TexturePacker.pack or PixmapPacker.pack to pack your TextureAtlas at runtime using the generateTextureAtlas method, this 9-patch information is lost. There's no way to give TexturePacker or PixmapPacker this information when packing.
I would suggest that there should be a version of the pack methods in TexturePacker and PixmapPacker which accepts this 9-patch info so that it comes out in the regions from generateTextureAtlas.
Reproduction steps/code
I wrote a sort of workaround in this code here which assumes the user will be packing from only one TextureAtlas and that all the names of all the textures will exactly match. However, this is an ugly hack. It would be better if TexturePacker and PixmapPacker handled this.
Version of LibGDX and/or relevant dependencies
All.
Please select the affected platforms
All platforms.
The text was updated successfully, but these errors were encountered: