Examples of AtlasPacker


Examples of com.ardor3d.extension.atlas.AtlasPacker

public class TestAtlasPacker {

    public static void main(final String[] args) {
        final int width = 512;
        final int height = 512;
        final AtlasPacker packer = new AtlasPacker(width, height);

        final Random rand = new Random();
        for (int i = 0; i < 2000; i++) {
            final AtlasNode node = packer.insert(rand.nextInt(100) + 10, rand.nextInt(100) + 10);
        }

        final JFrame frame = new JFrame("Pack");
        frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        final JPanel panel = new AtlasPainter(packer);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.