资源说明:Texture Atlas Generator/Packer written in Java using a single source file.
h1. Texture Atlas Generator A texture atlas generator/packer written in one single Java file. Currently it only supports loading and saving of PNG textures, this can easily be extended to other formats supported by Java's ImageIO class. Besides the texture atlas, a .txt file is also generated with texture coords for all the textures. Examples and further details are available at "my website":http://lukasz.dk/2011/04/18/texture-atlas-generator/ The texture packing algorithm used in the atlas generator is the "Lightmap Packing Algorithm":http://www.blackpawn.com/texts/lightmaps/ by "Black Pawn":http://www.blackpawn.com. The images are added to the atlas by area size (width x height), in descending order. The source code for this application is released into the Public Domain. h2. Building pre. javac AtlasGenerator.java h2. Usage pre. AtlasGeneratorh2. Example pre. AtlasGenerator atlas 2048 2048 images This will take all the PNG files in the _images_ directory next to application and pack them into one or more 2048x2048 atlases named "atlas1.png" to "atlasN.png", where N is the number of atlases generated. More than one atlas is generated if the PNG textures do not fit into one atlas.
本源码包内暂不包含可直接显示的源代码文件,请下载源码包。