/// <summary> /// Oggをサポートしているプラットフォームかどうか /// WebPlayer、StandAloneではOggが対応。MOBILEはMP3が対応なので、拡張子を入れ替える /// http://docs-jp.unity3d.com/Documentation/ScriptReference/WWW.GetAudioClip.html /// </summary> /// <returns>サポートしていればtrue</returns> public static bool IsSupportOggPlatform() { // WebPlayerの対応が5.4で終了したため5.4未満かどうかで処理を分ける. 2017/10/30 yoshida written. #if UNITY_5_4_OR_NEWER #if UNITY_STANDALONE || UNITY_WEBGL return(true); #else if (UtageToolKit.IsPlatformStandAlone()) { //無料版用にDLL化したときのため return(true); } return(false); #endif #else #if UNITY_STANDALONE || UNITY_WEBPLAYER || UNITY_WEBGL return(true); #else if (Application.isWebPlayer || UtageToolKit.IsPlatformStandAlone()) { //無料版用にDLL化したときのため return(true); } return(false); #endif #endif }
/// <summary> /// Oggをサポートしているプラットフォームかどうか /// WebPlayer、StandAloneではOggが対応。MOBILEはMP3が対応なので、拡張子を入れ替える /// http://docs-jp.unity3d.com/Documentation/ScriptReference/WWW.GetAudioClip.html /// </summary> /// <returns>サポートしていればtrue</returns> public static bool IsSupportOggPlatform() { #if UNITY_STANDALONE || UNITY_WEBPLAYER || UNITY_WEBGL return(true); #else if (Application.isWebPlayer || UtageToolKit.IsPlatformStandAlone()) { //無料版用にDLL化したときのため return(true); } return(false); #endif }