Beispiel #1
0
 /// <summary>
 /// Sets the current audio session category.
 ///
 /// The audio session's category defines how the app intends to use audio.
 /// Typically, you set the category before activating the session.
 /// You can also set the category while the session is active, but this results in an immediate route change.
 /// </summary>
 /// <returns>Returns operation result info</returns>
 /// <param name="category">The audio session category to apply to the audio session.</param>
 /// <param name="options">A mask of additional options for handling audio. For a list of constants, <see cref="ISN_AVAudioSessionCategoryOptions"/></param>
 public static SA_Result SetCategory(ISN_AVAudioSessionCategory category, ISN_AVAudioSessionCategoryOptions options)
 {
     return(ISN_AVLib.API.AudioSessionSetCategoryWithOptions(category, options));
 }
Beispiel #2
0
 public SA_Result AudioSessionSetCategoryWithOptions(ISN_AVAudioSessionCategory category, ISN_AVAudioSessionCategoryOptions options)
 {
     m_audioSessionCategory        = category;
     m_audioSessionCategoryOptions = options;
     return(new SA_Result());
 }
Beispiel #3
0
        public SA_Result AudioSessionSetCategoryWithOptions(ISN_AVAudioSessionCategory category, ISN_AVAudioSessionCategoryOptions options)
        {
#if UNITY_IPHONE
            var resultString = _ISN_AV_AudioSessionSetCategoryWithOptions((int)category, (int)options);
            var result       = JsonUtility.FromJson <SA_Result>(resultString);
            return(result);
#else
            return(null);
#endif
        }