Adobe Texture Format, or ATF is the recommended file type for fixed texture assets that are used with the Flash runtime's Stage3D API.
This guide is a reference for the following tools, which Adobe provides to create and manage ATF files (Adobe Texture Files):
ATF files rely on compression, and there are some limitations that you need to keep in mind.
An ATF file is a file container for storing texture data. The ATF file format achieves its lossy compression through the use of two common techniques: JPEG XR compression and block-based compression. JPEG XR compression provides a competitive method to save storage space and network bandwidth. Block-based compression provides a way to reduce texture memory usage on the client, at a fixed ratio of 1:8 compared to RGBA textures. ATF supports three types of block-based compression: DXT1, ETC1, and PVRTC.
In ATF files, compression is performed on two levels. The first type of compression is optional block-based compression. On top of that, standard lossless or lossy JPEG XR compression is applied. Other features of the ATF file format include:
Optionally embedding a complete cube map (sky map)
Optional support for selecting an internal color space (4:4:4, 4:2:2, and 4:2:0)
ATF files have various limitations that are the direct result of existing hardware capabilities on various mobile devices. These limitations include:
The maximum size for a texture is 2048 by 2048 pixels.
The length of each side of a texture must be a power of two: 1, 2, 4, 8, 16, 32, 64, 128, 256, 512, 1024, or 2048.
To use block-based compression a texture's dimensions must be equal (the texture must be a square): 1x1, 2x2, 4x4, 8x8, 16x16, 32x32, 64x64, 128x128, 256x256, 512x512, 1024x1024, or 2048x2048.
Block-based compression can't be used with an alpha channel (transparency) of any kind at this time.
If your texture uses the maximum 2048x2048 size, you must provide at least one regular mipmap level. This is because certain devices only allow texture sizes up to 1024x1024. The Flash runtime will automatically switch the texture size to 1024x1024 if necessary.
The png2atf command-line utility converts a PNG file to an ATF file. The resulting ATF file can then be used with the Texture class's
uploadCompressedTextureFromByteArray() method. It takes any valid PNG file as input. By default it converts the PNG file to either an RGB or RGBA ATF file, depending on whether the PNG file includes transparency. The
png2atf tool can optionally create a texture with block-based compression if the source PNG does not have transparency.
To convert a PNG file to an RGB or RGBA ATF file run the png2atf command:
You must Sign up as a member of Effecthub to view the content.