AudioPlayer should be extended to handle audio output from the Engine.
- Note
- Audio playback control operations such as on-platform button presses must be routed through the PlaybackController.
- See also
- PlaybackController
- 
TemplateRuntime.renderPlayerInfo() 
◆ playerActivityChanged()
      
        
          | void com.amazon.aace.alexa.AudioPlayer.playerActivityChanged | ( | PlayerActivity | state | ) |  | 
      
 
Notifies the platform implementation of a change in audio playback state
- Parameters
- 
  
    | state | The new playback state |  
 
 
 
◆ getPlayerPosition()
      
        
          | final long com.amazon.aace.alexa.AudioPlayer.getPlayerPosition | ( |  | ) |  | 
      
 
Returns the current playback position of the audio player. If the audio source is not playing, the most recent position played will be returned.
- Returns
- The audio player's playback position in milliseconds, or TIME_UNKNOWNif the current media position is unknown or invalid.
 
 
◆ getPlayerDuration()
      
        
          | final long com.amazon.aace.alexa.AudioPlayer.getPlayerDuration | ( |  | ) |  | 
      
 
Returns the playback duration of the audio player.
- Returns
- The audio player's playback duration in milliseconds, or TIME_UNKNOWNif the current media position is unknown or invalid.
 
 
◆ TIME_UNKNOWN
  
  | 
        
          | final long com.amazon.aace.alexa.AudioPlayer.TIME_UNKNOWN = -1 |  | static | 
 
Used when audio time is unknown or indeterminate. 
 
 
 
  
    
      Alexa Auto SDK 2.3.0 - Copyright 2017-2020 Amazon.com, Inc. or its affiliates. All Rights Reserved.
      
        Licensed under the Apache License, Version 2.0