Shaka Packager SDK
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends
Public Member Functions | List of all members
shaka::hls::HlsNotifier Class Referenceabstract
Inheritance diagram for shaka::hls::HlsNotifier:
shaka::hls::SimpleHlsNotifier

Public Member Functions

 HlsNotifier (HlsPlaylistType playlist_type)
 
virtual bool Init ()=0
 
virtual bool NotifyNewStream (const MediaInfo &media_info, const std::string &playlist_name, const std::string &stream_name, const std::string &group_id, uint32_t *stream_id)=0
 
virtual bool NotifyNewSegment (uint32_t stream_id, const std::string &segment_name, uint64_t start_time, uint64_t duration, uint64_t start_byte_offset, uint64_t size)=0
 
virtual bool NotifyEncryptionUpdate (uint32_t stream_id, const std::vector< uint8_t > &key_id, const std::vector< uint8_t > &system_id, const std::vector< uint8_t > &iv, const std::vector< uint8_t > &protection_system_specific_data)=0
 
virtual bool Flush ()=0
 
HlsPlaylistType playlist_type () const
 

Detailed Description

Definition at line 20 of file hls_notifier.h.

Member Function Documentation

virtual bool shaka::hls::HlsNotifier::Flush ( )
pure virtual

Process any current buffered states/resources.

Returns
true on success, false otherwise.

Implemented in shaka::hls::SimpleHlsNotifier.

virtual bool shaka::hls::HlsNotifier::Init ( )
pure virtual

Intialize the notifier.

Returns
true on sucess, false otherwise.

Implemented in shaka::hls::SimpleHlsNotifier.

virtual bool shaka::hls::HlsNotifier::NotifyEncryptionUpdate ( uint32_t  stream_id,
const std::vector< uint8_t > &  key_id,
const std::vector< uint8_t > &  system_id,
const std::vector< uint8_t > &  iv,
const std::vector< uint8_t > &  protection_system_specific_data 
)
pure virtual
Parameters
stream_idis the value set by NotifyNewStream().
key_idis the key ID for the stream.
system_idis the DRM system ID in e.g. PSSH boxes. For example this can be used to determine the KEYFORMAT attribute for EXT-X-KEY.
ivis the new initialization vector.
protection_system_specific_datais the DRM specific data. The interpretation of this data is up to the implementation, possibly using system_id to determine how to interpret the data.

Implemented in shaka::hls::SimpleHlsNotifier.

virtual bool shaka::hls::HlsNotifier::NotifyNewSegment ( uint32_t  stream_id,
const std::string &  segment_name,
uint64_t  start_time,
uint64_t  duration,
uint64_t  start_byte_offset,
uint64_t  size 
)
pure virtual
Parameters
stream_idis the value set by NotifyNewStream().
segment_nameis the name of the new segment.
start_timeis the start time of the segment in timescale units passed in media_info.
durationis also in terms of timescale.
start_byte_offsetis the offset of where the subsegment starts. This should be 0 if the whole segment is a subsegment.
sizeis the size in bytes.

Implemented in shaka::hls::SimpleHlsNotifier.

virtual bool shaka::hls::HlsNotifier::NotifyNewStream ( const MediaInfo &  media_info,
const std::string &  playlist_name,
const std::string &  stream_name,
const std::string &  group_id,
uint32_t *  stream_id 
)
pure virtual
Parameters
media_infospecifies the stream.
playlist_nameis the name of the playlist that this stream should go.
stream_nameis the name of this stream.
group_idis the group ID for this stream.
stream_idis set to a value so that it can be used to call the other methods. If this returns false, the stream_id may be set to an invalid value.
Returns
true on sucess, false otherwise.

Implemented in shaka::hls::SimpleHlsNotifier.

HlsPlaylistType shaka::hls::HlsNotifier::playlist_type ( ) const
inline
Returns
the playlist type.

Definition at line 80 of file hls_notifier.h.


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