@1x and @2x atlases from the same source sprites: the high-resolution atlas serves retina or high-DPI displays; the low-resolution one serves standard displays.
Each variant specifies a scale factor, an optional filename suffix, and a resampling mode. All variants are produced from the same loaded source sprites — images are only read from disk once.
Configuration
Single variant
To produce a single scaled atlas:Multiple variants
Multiple variants require a project file:.fpsheet
Scale modes
- smooth
- fast
- scale2x
- scale3x
- hq2x
- eagle
Resamples with Lanczos3. Use it for photographic sprites or mixed content.Best for realistic artwork, photos, and general-purpose scaling.
Output structure
With two variants and atlas name"sprites", the output directory contains:
meta.scale reflects its variant’s scale factor:
Multi-pack with variants
When multipack overflows on a variant, sheets are numbered before the suffix:Scale variants each run an independent multipack sequence. The @2x variant may need multiple sheets while @1x fits in one.
Loading variants at runtime
- PixiJS
- Phaser 3
- Unity
Detect device pixel ratio and load the appropriate variant:
Technical details
Each variant runs a full independent pipeline: sprites are scaled, trim rects are recomputed, the atlas is repacked, and the output is recompressed. Trim rects, nine-patch borders, and polygon vertices are all scaled proportionally so data file values are always in the variant’s own pixel space. Pivot points are normalized and scale-independent; they are copied to each variant unchanged. A scale factor of exactly1.0 skips resampling entirely and copies source pixels directly.
Pixel art modes (scale2x, scale3x, hq2x, eagle) apply their integer upscaler first, then resize to the exact target dimensions with nearest-neighbor if the factor does not align with the algorithm’s native multiplier. For example, scale2x at factor 4.0 produces a 2× EPX intermediate and then doubles it again with nearest-neighbor to reach 4×. Metadata (trim rects, nine-patch borders, polygon vertices) is always scaled by the requested factor, not by the algorithm’s native multiplier.
Best practices
Use power-of-two scales
For best results with GPU texture filtering, use power-of-two scale factors:Choose the right scale mode
- Realistic art / photos: Use
smooth(Lanczos3) - Pixel art at 2×: Use
scale2xorhq2x - Pixel art at 3×: Use
scale3x - Fast processing / crisp edges: Use
fast(nearest-neighbor)
Optimize for target platforms
Mobile devices often have high DPI screens but limited memory:TexturePacker calls these “Variants” and uses the same suffix convention. The
meta.scale field in data files is a string (e.g. "2", "0.5") to match TexturePacker’s serialization.