Version: Unity 6.7 Beta (6000.7)
Language : English
Use the legacy Text Core in UI Toolkit
Test UI

Migrate static font assets to Advanced Text Generator

The default Advanced Text Generator doesn’t support static font assets. If your existing project uses them, you must migrate them so your UI text elements render correctly.

The recommended way to migrate is to convert the static font assets to dynamic with the Font Asset Migration window. The conversion happens in place, so all references to the font asset keep working, and the source font is subset so only the baked characters ship in builds. You can optionally keep the baked atlas.

You can also migrate manually by creating dynamic font assets yourself, either to reduce memory footprint or to optimize startup performance.

Convert static font assets to dynamic

The Font Asset Migration window lists the static font assets in your project and converts them to dynamic. To open it, do one of the following:

  • From the menu, select Window > Text > Font Asset Migration.
  • In the Project window, select a static font asset, then in the Inspector window, select Open Font Asset Migration Window.

To convert static font assets:

  1. In the Font Asset Migration window, select a font asset from the list to review its source font, baked glyphs, and atlas.
  2. Choose what the conversion keeps. By default, SDFAA font assets use Drop Everything and the Advanced Text Generator rasterizes glyphs on demand into a fresh atlas. To avoid rasterization at startup, select Keep Atlas. If the asset is still used by the legacy standard text generator, select Keep Atlas and Legacy Tables to also keep the character table and font feature table.
  3. Select Convert Font Asset to convert the selected asset, or Convert All to convert every asset in the list.
  4. The first time you convert, Unity displays a font license notice. Converting embeds subset font data in your builds, which static font assets didn’t do. Confirm that the font licenses permit embedding, then select Convert.

Each converted font asset switches to the Dynamic atlas population mode and keeps its references. Unity subsets the source font to the characters baked into the atlas, so builds don’t grow by the size of the full font file. You can review or change the subset in the Font Subsetting section of the Inspector.

Some font assets need attention before conversion:

  • If a font asset has baked glyphs but no reference to its source font file, it can’t be converted. Assign the source font in the Inspector window first.
  • If a font asset has no baked glyphs and no source font reference, Unity converts it to an empty dynamic font asset. Assign a source font in the Inspector window to populate it.

Reduce memory footprint

If you created the static font asset mainly to ship a smaller character set, create a dynamic font asset and subset its source font.

Subsetting ships a smaller font file, and because a dynamic font asset doesn’t need a pre-populated atlas texture, dropping the atlas reduces memory overhead further. For reference, an atlas texture in Alpha 8 is approximately:

  • 1024 × 1024 → ~1 MB
  • 2048 × 2048 (common for CJK) → ~4 MB

To migrate, do the following:

  1. Identify the characters or scripts required by your UI.
  2. Create a dynamic font asset from the original font file.
  3. Subset the source font in the font asset’s Font Subsetting section.
  4. Replace all references to the static font asset (USS/UXML/C#).

Optimize startup or first-frame behavior

If you used a static font asset mainly to pre-populate an atlas (to reduce runtime glyph generation during startup), the equivalent workflow in Advanced Text Generator is to use a dynamic font asset and pre-populate its atlas with a chosen character set.

Note: With SDFAA atlas rendering mode, many projects no longer need to pre-populate an atlas for acceptable first-frame performance. However, if you still require control or warm-up of glyph generation, Advanced Text Generator supports the workflow through a dynamic font asset.

To migrate, do the following:

  1. Create or select a dynamic font asset
  2. In the Font Asset Creator window, load the dynamic font asset.
  3. Populate the atlas with the desired character set.
  4. Replace all references to the static font asset (USS/UXML/C#).

Additional resources

Use the legacy Text Core in UI Toolkit
Test UI