Class StageAudioManager

java.lang.Object
com.amazonaws.ivs.broadcast.StageAudioManager

@RequiresApi(api=28) public class StageAudioManager extends Object
Manages audio settings for all stages.
  • Method Details

    • setAudioModeManagementEnabled

      public void setAudioModeManagementEnabled(boolean isEnabled)
      Use this method to turn off the audio mode management (including for Bluetooth) done by the IVS SDK if your application wants to manage this itself. Please see AudioManager#setMode in the Android SDK.

      You can still use the various presets and the source / usage / content type values which affect AAudio stream attributes, and are important for things like echo cancellation.

      Parameters:
      isEnabled - Whether the audio mode management done by this class is enabled, the default is true.
    • setPreset

      public void setPreset(@NonNull StageAudioManager.UseCasePreset preset) throws IllegalStateException
      Throws:
      IllegalStateException
    • setConfiguration

      public void setConfiguration(@NonNull StageAudioManager.Source source, @NonNull StageAudioManager.ContentType contentType, @NonNull StageAudioManager.Usage usage) throws IllegalStateException
      Throws:
      IllegalStateException
    • getSource

      @NonNull public StageAudioManager.Source getSource()
    • getContentType

      @NonNull public StageAudioManager.ContentType getContentType()
    • getUsage

      @NonNull public StageAudioManager.Usage getUsage()
    • getInstance

      public static StageAudioManager getInstance(@NonNull android.content.Context context)
      Returns an instance of the StageAudioManager.
      Parameters:
      context - The current application context
      Returns:
      the instance of the StageAudioManager