Skip to content

Inspector 設定

Font2Texture Generator の Inspector 設定項目の詳細解説

機能概要

Inspector 設定 では、Font2Texture Generator のコンポーネントで利用できる各種パラメータを調整できます。

フォントの選択からテクスチャの出力まで、すべての設定を Inspector から行えます。

基本設定

Font Settings (フォント設定)

Inspector 表示説明設定範囲Parameter
Target Font使用するフォントアセット(Inspector 表示名)FontfontAsset
Font Pathフォントファイルのパス(Font Asset 未設定時に使用)Assets/...fontPath
Font Size生成する数字のフォントサイズ8-512fontSize
Text Color数字の色ColortextColor
Background Color背景の色(透明推奨)ColorbackgroundColor

Spacing Settings (間隔設定)

Inspector 表示説明設定範囲Parameter
Character Spacing (px)各数字間のスペース(ピクセル)0-100characterSpacing

Texture Settings (テクスチャ設定)

Inspector 表示説明設定範囲Parameter
Widthベースとなるテクスチャ幅(Inspector 表示名)128-4096baseTextureWidth
Heightテクスチャの高さ(Inspector 表示名)32-2048textureHeight

出力設定

Output Settings (出力設定)

Inspector 表示説明設定範囲Parameter
Output Folder出力先フォルダ(DefaultAsset)Folder 選択outputFolder
Full Output Path出力先パス(Inspector で表示されるフルパス)表示のみoutputFolderPath + outputFileName
File Name出力ファイル名(拡張子なし、Inspector 表示名)文字列outputFileName

Preview (プレビュー)

Inspector 表示説明設定範囲Parameter
Generated Texture生成されたテクスチャのプレビュー表示のみgeneratedTexture

生成ボタン

Inspector 表示説明動作実行条件
[Generate Number Texture]Number Texture を生成・保存(Inspector のボタン)ボタンクリックで実行Unity Editor 環境のみ

パラメータの推奨設定

  • Font Size: 128 (標準的なサイズ、拡大縮小に対応)
  • Character Spacing: 0 (font によって変わるため調整推奨)
  • Base Texture Width: 1280 (10文字 × 128px)