Skip to content

Export & Texture Optimization

Preflight separates exporting from texture optimization so the common case stays fast while power users retain full control.

File > Export… (Cmd+E) opens a standard save panel. Pick a destination, hit Save. The export uses your current texture optimization settings (or sensible defaults if you haven’t changed them).

Preflight supports two export modes:

ModeDescription
Export (Fixed)Preserves the scene graph structure — references, payloads, sublayers, and variants are kept intact. Produces a .usdz archive.
Export (Flattened)Collapses the full composition into a single layer. Useful for delivery to renderers or platforms that don’t support layered USD.

Both modes apply your texture optimization settings during export.

File > Optimize Textures… opens a dedicated panel where you configure how textures are processed during export. Settings are saved across sessions — you set them once and every future export uses them.

Controls the texture container format written into the exported archive.

OptionDescription
AutomaticSelects the best format for your current workflow. Resolves to PNG for OpenUSD targets and AVIF for RealityKit targets.
PNGLossless. Universally supported. Larger file size.
JPEGLossy. Good compression for photographic textures. No alpha channel.
AVIFModern lossy/lossless codec. Excellent compression with high quality. Supported by RealityKit on macOS 13+ and visionOS.
KTX2GPU-compressed container (ASTC/BC payloads). Used as a Metal pipeline intermediate. Not a scene-referenced format for Apple runtimes — use only if your pipeline explicitly requires it.

Controls the compression effort when converting textures.

OptionDescription
AutomaticUses the target workflow default (Fast for quick iterations, Best for final delivery).
FastMinimal compression time. Good for iteration.
BalancedModerate compression with good quality.
BestMaximum quality. Slower compression. Recommended for final export.

Limits the largest dimension (width or height) of exported textures. Textures exceeding this size are downscaled proportionally.

OptionWhen to use
AutomaticUses the target default (4096 px for RealityKit, unlimited for OpenUSD).
1024–8192Override for specific size budgets.

Controls whether mipmaps are generated for exported textures.

  • Automatic: On for RealityKit, off for OpenUSD.
  • On / Off: Explicit override.

Mipmaps improve rendering performance for textures viewed at varying distances but increase file size.

When enabled, Preflight computes PSNR (Peak Signal-to-Noise Ratio), MSE, and RMS metrics comparing the compressed texture against the original. Useful for validating that compression hasn’t degraded visual quality below acceptable thresholds.

Requires AppleTextureConverter (ships with Xcode).

Optional fields for explicit color space conversion during export.

  • Source: The color space of your input textures (e.g., DisplayP3).
  • Output: The target color space (e.g., sRGB).

Leave blank to preserve the original color space. Only specify these when your pipeline requires an explicit gamut conversion.

The Automatic setting adapts to your current workflow target:

SettingOpenUSDRealityKit
FormatPNGAVIF
QualityFast
Max SizeUnlimited4096 px
MipmapsOffOn
Quality MetricsOffOn

GPU-accelerated texture compression is provided by AppleTextureConverter, which ships as part of Xcode. Preflight links it in-process (no subprocess spawning, sandbox-safe).

When available, it enables:

  • ASTC and BC1–7 compression
  • GPU-accelerated mipmap generation
  • PSNR/MSE quality comparison
  • Memory-to-memory conversion

If Xcode is not installed, Preflight falls back to open-source conversion backends. A status indicator in the Optimize Textures panel shows availability.

Texture optimization is also available through the command line:

Terminal window
# Analyze textures in a scene
preflighttool texture analyze scene.usdz --target RealityKit
# Convert a single texture
preflighttool texture convert albedo.png albedo.avif --format avif --quality best
# Export with current preferences
preflighttool export scene.usdz output.usdz --target RealityKit