Libgdx Texture Packer ((new)) May 2026
// 1. Load the atlas TextureAtlas atlas = new TextureAtlas(Gdx.files.internal("player.atlas")); // 2. Get a single region (a sprite from the atlas) TextureRegion playerStand = atlas.findRegion("player_idle_01");
// (input directory, output directory, atlas file name) TexturePacker.process(settings, "raw-assets/player", "android/assets/", "player"); libgdx texture packer
// Don't forget to dispose! atlas.dispose(); The texture packer uses your folder structure to create region names. This is where the Texture Packer comes in
If you're making a game with libGDX, you will eventually need to draw many images (sprites) on the screen. Loading each image as a separate texture is incredibly inefficient and slow. This is where the Texture Packer comes in. What is the Texture Packer? The Texture Packer is a tool that takes multiple individual image files (PNG, JPG, etc.) and combines them into a single large image, called a Texture Atlas . It also generates a metadata file (usually .atlas ) that tells your game where each original image lives inside that big image. called a Texture Atlas .