Show Menu
TOPICS×

MediaPlayer methods for accessing MediaResource information

The methods in the MediaPlayerItem class allow you to obtain information about the content stream represented by a loaded MediaResource.
Method Description
Live stream
function get isLive():Boolean;
True if the stream is live; false if it is VOD.
DRM protected
function get isProtected():Boolean;
True if the stream is DRM protected.
function get drmMetadataInfos(): Vector.<DRMMetadataInfo>;
Lists all the DRM metadata objects discovered in the manifest.
Closed captions
function get hasClosedCaptions():Boolean;
True if closed-caption tracks are available.
function get closedCaptionsTracks():Vector.<ClosedCaptionsTrack>;
Provides a list of available closed-caption tracks.
function get selectedClosedCaptionsTrack():ClosedCaptionsTrack
Retrieves the current closed caption track selected with SelectClosedCaptionsTrack .
selectClosedCaptionsTrack (closedCaptionsTrack: com.adobe.mediacore.info:ClosedCaptionsTrack )
Sets a closed-caption track to be the current closed-caption track.
Alternate audio tracks
function get hasAlternateAudio():Boolean;
True if the stream has alternate audio tracks.
Tip: The main (default) audio track is also part of the alternate audio track list.
TVSDK for Desktop HLS considers the main audio track to be one of the items in the alternate audio track list. Because of this, the only case where MediaPlayerItem.hasAlternateAudio returns false is when the stream has no audio at all. If the content has only one audio track, this method returns true, and get AudioTracks returns a list with a single element (the default audio track).
function get audioTracks():Vector.<AudioTrack>; Provides a list of available alternate audio tracks.
function get audioTracks():Vector.<AudioTrack>;
Provides a list of available alternate audio tracks.
function get selectedAudioTrack():AudioTrack;
Retrieves the audio track selected with selectAudioTrack .
selectAudioTrack(audioTrack: AudioTrack )
Selects an audio track to be the current audio track.
Timed metadata
function get hasTimedMetadata():Boolean;
True if the stream has associated timed metadata.
function get timedMetadata():Vector.<TimedMetadata>;
Provides a list of the timed metadata objects associated with the stream.
function get isDynamic():Boolean;
True if the stream is a multiple bit rate (MBR) stream.
function get profiles():Vector.<Profile>;
Provides a list of the associated bit rate profiles. For each profile, you can retrieve its bit rate and the height and width of the profile.
Trick play
function get isTrickPlaySupported():Boolean;
True if the player supports fast forward, rewind, and resume.
function get availablePlaybackRates():Vector.<Number>
Provides the list of available playback rates in the context of the trick-play feature.
Media player
function get player():MediaPlayer
Returns the media player currently associated with this player.
Media resource
function get resource():MediaResource;
Returns the media resource associated with this item.
function get resourceId():int
Returns the media identifier associated with this item.