Package arc.packer

Class TexturePacker

java.lang.Object
arc.packer.TexturePacker

public class TexturePacker extends Object
  • Constructor Details

  • Method Details

    • setRootDir

      public void setRootDir(File rootDir)
      Parameters:
      rootDir - Used to strip the root directory prefix from image file names, can be null.
    • addImage

      public void addImage(File file)
    • addImage

      public void addImage(Pixmap image, String name)
    • pack

      public void pack(File outputDir, String packFileName)
    • process

      public static void process(String input, String output, String packFileName)
      Packs using defaults settings.
      See Also:
    • process

      public static void process(TexturePacker.Settings settings, String input, String output, String packFileName)
      Parameters:
      input - Directory containing individual images to be packed.
      output - Directory where the pack file and page images will be written.
      packFileName - The name of the pack file. Also used to name the page images.
    • isModified

      public static boolean isModified(String input, String output, String packFileName, TexturePacker.Settings settings)
      Returns:
      true if the output file does not yet exist or its last modification date is before the last modification date of the input file
    • processIfModified

      public static boolean processIfModified(String input, String output, String packFileName)
    • processIfModified

      public static boolean processIfModified(TexturePacker.Settings settings, String input, String output, String packFileName)
    • main

      public static void main(String[] args) throws Exception
      Throws:
      Exception