58c7ad86 by David LaPalomento

Add property and event documentation

Create some high-level descriptions of the properties and events the plugin exports.
1 parent 6e0688fa
Showing 1 changed file with 41 additions and 1 deletions
...@@ -46,11 +46,51 @@ support for: ...@@ -46,11 +46,51 @@ support for:
46 46
47 - Alternate audio and video tracks 47 - Alternate audio and video tracks
48 - Subtitles 48 - Subtitles
49 - Dynamic bitrate switching
50 - Segment codecs _other than_ H.264 with AAC audio 49 - Segment codecs _other than_ H.264 with AAC audio
51 - Live streams 50 - Live streams
52 - Internet Explorer 8 51 - Internet Explorer 8
53 52
53 ### Runtime Properties
54 #### player.hls.master
55 Type: `object`
56
57 An object representing the parsed master playlist. If a media playlist
58 is loaded directly, a master playlist with only one entry will be
59 created.
60
61 #### player.hls.media
62 Type: `object`
63
64 An object representing the currently selected media playlist. This is
65 the playlist that is being referred to when a additional video data
66 needs to be downloaded.
67
68 #### player.hls.mediaIndex
69 Type: `number`
70
71 The index of the next video segment to be downloaded from
72 `player.hls.media`.
73
74 #### player.hls.selectPlaylist
75 Type: `function`
76
77 A function that returns the media playlist object to use to download
78 the next segment. It is invoked by the plugin immediately before a new
79 segment is downloaded. You can override this function to provide your
80 adaptive streaming logic. You must, however, be sure to return a valid
81 media playlist object that is present in `player.hls.master`.
82
83 ### Events
84 #### loadedmetadata
85
86 Fired after the first media playlist is downloaded for a stream.
87
88 #### loadedmanifest
89
90 Fired immediately after a new master or media playlist has been
91 downloaded. By default, the plugin only downloads playlists as they
92 are needed.
93
54 ## Hosting Considerations 94 ## Hosting Considerations
55 Unlike a native HLS implementation, the HLS plugin has to comply with 95 Unlike a native HLS implementation, the HLS plugin has to comply with
56 the browser's security policies. That means that all the files that 96 the browser's security policies. That means that all the files that
......