Shaka Player Embedded
Classes | Public Member Functions | List of all members
shaka::Track Class Referencefinal

#include <track.h>

Classes

class  Impl
 

Public Member Functions

 Track ()
 
 Track (js::Track &&internal)
 
 Track (const Track &)
 
 Track (Track &&)
 
 ~Track ()
 
Trackoperator= (const Track &)
 
Trackoperator= (Track &&)
 
double id () const
 
bool active () const
 
const std::string & type () const
 
double bandwidth () const
 
const std::string & language () const
 
shaka::optional< std::string > label () const
 
shaka::optional< std::string > kind () const
 
shaka::optional< double > width () const
 
shaka::optional< double > height () const
 
shaka::optional< double > frame_rate () const
 
shaka::optional< std::string > mime_type () const
 
shaka::optional< std::string > codecs () const
 
shaka::optional< std::string > audio_codec () const
 
shaka::optional< std::string > video_codec () const
 
bool primary () const
 
const std::vector< std::string > & roles () const
 
shaka::optional< double > video_id () const
 
shaka::optional< double > audio_id () const
 
shaka::optional< double > channels_count () const
 
shaka::optional< double > audio_bandwidth () const
 
shaka::optional< double > video_bandwidth () const
 
js::Track GetInternal () const
 

Detailed Description

An object describing a media track. This object should be treated as read-only as changing any values does not have any effect. This is the public view of an audio/video paring (variant type) or text track (text type).

Definition at line 44 of file track.h.

Constructor & Destructor Documentation

§ Track() [1/4]

shaka::Track::Track ( )

Definition at line 72 of file track.cc.

§ Track() [2/4]

shaka::Track::Track ( js::Track &&  internal)

Definition at line 73 of file track.cc.

§ Track() [3/4]

shaka::Track::Track ( const Track )
default

§ Track() [4/4]

shaka::Track::Track ( Track &&  )
default

§ ~Track()

shaka::Track::~Track ( )

Definition at line 76 of file track.cc.

Member Function Documentation

§ active()

bool shaka::Track::active ( ) const

If true, this is the track being streamed (another track may be visible/audible in the buffer).

Definition at line 85 of file track.cc.

§ audio_bandwidth()

shaka::optional< double > shaka::Track::audio_bandwidth ( ) const

(only for variant tracks) The audio stream's bandwidth if known.

Definition at line 157 of file track.cc.

§ audio_codec()

shaka::optional< std::string > shaka::Track::audio_codec ( ) const

The audio codecs string provided in the manifest, if present.

Definition at line 129 of file track.cc.

§ audio_id()

shaka::optional< double > shaka::Track::audio_id ( ) const

(only for variant tracks) The audio stream id.

Definition at line 149 of file track.cc.

§ bandwidth()

double shaka::Track::bandwidth ( ) const

The bandwidth required to play the track, in bits/sec.

Definition at line 93 of file track.cc.

§ channels_count()

shaka::optional< double > shaka::Track::channels_count ( ) const

The count of the audio track channels.

Definition at line 153 of file track.cc.

§ codecs()

shaka::optional< std::string > shaka::Track::codecs ( ) const

The audio/video codecs string provided in the manifest, if present.

Definition at line 125 of file track.cc.

§ frame_rate()

shaka::optional< double > shaka::Track::frame_rate ( ) const

The video framerate provided in the manifest, if present.

Definition at line 117 of file track.cc.

§ GetInternal()

js::Track shaka::Track::GetInternal ( ) const

INTERNAL USE ONLY: Get the internal representation of this object.

Definition at line 166 of file track.cc.

§ height()

shaka::optional< double > shaka::Track::height ( ) const

The video height provided in the manifest, if present.

Definition at line 113 of file track.cc.

§ id()

double shaka::Track::id ( ) const

The unique ID of the track.

Definition at line 81 of file track.cc.

§ kind()

shaka::optional< std::string > shaka::Track::kind ( ) const

(only for text tracks) The kind of text track, either 'caption' or 'subtitle'.

Definition at line 105 of file track.cc.

§ label()

shaka::optional< std::string > shaka::Track::label ( ) const

The track label, which is unique text that should describe the track.

Definition at line 101 of file track.cc.

§ language()

const std::string & shaka::Track::language ( ) const

The language of the track, or 'und' if not given. This is the exact value provided in the manifest; it may need to be normalized.

Definition at line 97 of file track.cc.

§ mime_type()

shaka::optional< std::string > shaka::Track::mime_type ( ) const

The MIME type of the content provided in the manifest.

Definition at line 121 of file track.cc.

§ operator=() [1/2]

Track & shaka::Track::operator= ( const Track )
default

§ operator=() [2/2]

Track & shaka::Track::operator= ( Track &&  )
default

§ primary()

bool shaka::Track::primary ( ) const

True indicates that this in the primary language for the content. This flag is based on signals from the manifest. This can be a useful hint about which language should be the default, and indicates which track Shaka will use when the user's language preference cannot be satisfied.

Definition at line 137 of file track.cc.

§ roles()

const std::vector< std::string > & shaka::Track::roles ( ) const

The roles of the track, e.g. 'main', 'caption', or 'commentary'.

Definition at line 141 of file track.cc.

§ type()

const std::string & shaka::Track::type ( ) const

The type of track, either 'variant' or 'text'.

Definition at line 89 of file track.cc.

§ video_bandwidth()

shaka::optional< double > shaka::Track::video_bandwidth ( ) const

(only for variant tracks) The video stream's bandwidth if known.

Definition at line 161 of file track.cc.

§ video_codec()

shaka::optional< std::string > shaka::Track::video_codec ( ) const

The video codecs string provided in the manifest, if present.

Definition at line 133 of file track.cc.

§ video_id()

shaka::optional< double > shaka::Track::video_id ( ) const

(only for variant tracks) The video stream id.

Definition at line 145 of file track.cc.

§ width()

shaka::optional< double > shaka::Track::width ( ) const

The video width provided in the manifest, if present.

Definition at line 109 of file track.cc.


The documentation for this class was generated from the following files: