forceToMono
Force audioclips to mono sound type, so all audio plays through a single channel.
読み終わるまでの所要時間 1 分最終更新 1ヶ月前
Definition
- Type: Property
- Namespace: UnityEditor
- Assembly: UnityEditor.CoreModule
public bool forceToMono { get; set; }
Examples
using UnityEngine;using UnityEditor;public class Example : AssetPostprocessor{ void OnPreprocessAudio() { AudioImporter audioImporter = assetImporter as AudioImporter; if (assetPath.Contains("mono")) { audioImporter = assetImporter as AudioImporter; audioImporter.forceToMono = true; } }}