Class AWTImageUtil

java.lang.Object
com.ardor3d.image.util.awt.AWTImageUtil

public abstract class AWTImageUtil extends Object
Utility methods for converting Ardor3D Images to AWT BufferedImages.
  • Constructor Details

    • AWTImageUtil

      public AWTImageUtil()
  • Method Details

    • convertToAWT

      public static List<BufferedImage> convertToAWT(Image input)
      Convert the given Ardor3D Image to a List of BufferedImages. It is a List because Ardor3D Images may contain multiple layers (for example, in the case of cube maps or 3D textures).
      Parameters:
      input - the Ardor3D Image to convert
      Returns:
      the BufferedImage(s) created in the conversion
    • convertToAWT

      public static List<BufferedImage> convertToAWT(Image input, Color tint)
      Convert the given Ardor3D Image to a List of BufferedImages. It is a List because Ardor3D Images may contain multiple layers (for example, in the case of cube maps or 3D textures). The given AWT Color is used to modulate or "tint" the returned image. TODO: Add support for more formats.
      XXX: Note that only images of data type ImageDataType.UnsignedByte and ImageDataFormat of RGB or RGBA are currently supported.
      Parameters:
      input - the Ardor3D Image to convert
      tint - the Color to apply to the generated image
      Returns:
      the BufferedImage(s) created in the conversion